You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
36 lines
909 B
36 lines
909 B
|
|
Cut parts of a line by *byte position*, *character* and *field*.
|
|
|
|
Cut command slices a line and extracts the text. It is necessary to specify option with command otherwise it gives error.
|
|
|
|
|
|
[source,bash]
|
|
----
|
|
cut OPTION [FILE]
|
|
e.g.
|
|
cut $LLO_DATAFILE | head -5
|
|
----
|
|
|
|
*-b(byte):* To extract the specific bytes, you need to follow -b option with the list of byte numbers separated by comma.
|
|
|
|
[source,bash]
|
|
----
|
|
cut -b 1,2,3 $LLO_DATAFILE | head -5
|
|
----
|
|
|
|
|
|
[INFO]
|
|
====
|
|
|
|
DATAFILE
|
|
|
|
The datafile contains aggregate individual statistics for 67 NBA seasons. from basic box-score attributes such as points, assists, rebounds etc., to more advanced money-ball like features such as Value Over Replacement.
|
|
|
|
Take a look in
|
|
link:https://git.swarmlab.io:3000/llo/LabLearningObject/src/branch/master/data/nba_statistics_glossary[Glossary^]
|
|
for a detailed column description
|
|
|
|
ENVIRONMENT VARIABLE: LLO_DATAFILE
|
|
|
|
====
|
|
|
|
|