OOMMF Home next up previous contents index
Next: Platform-Independent Make: pimake Up: Command Line Utilities Previous: Calculating H Fields from

ODT Column Extraction: odtcols

The odtcols utility extracts column subsets from ODT data table files.

The odtcols launch command is:

tclsh oommf.tcl odtcols [standard options] [-s] [-w colwidth] \
   [-f format] [col ...] <infile >outfile
Produces a file summary instead of column extraction. Output includes table titles, column and row counts, and the header for each specified column. If no columns are specified, then the headers for all the columns are listed.
-w colwidth
Minimum horizontal spacing to provide for each column on output. Optional. Default value is 15.
-f format
C printf-style format string for each output item. Optional. Default is "%-${colwidth}s".
col ...
Output column selections. These may either be integers representing the position of the column in the input data (with the first column numbered as 1), or else arbitrary strings used for case-insensitive glob-style matching against the column headers. The columns are output in match order, obtained by processing the column selections from left to right. If no columns are specified then by default all columns are selected.
Odtcols reads its input from stdin. Use the redirection operator ``<'' to read input from a file.
Odtcols writes its output to stdout. Use the redirection operator ``>'' to send the output to a file.
Commonly the -s switch is used in a first pass, to reveal the column headers; specific column selections may then be made in a second, separate invocation.

OOMMF Home next up previous Contents index

OOMMF Documentation Team
January 15, 2004