peek
peek
Take a peek at tab-delimited files
Usage
peek <file.tsv> [buffer]
Functions
| Name | Description |
|---|---|
| justify | Calculates the spacing for justifying to the right |
| max_string | Given a list of strings, finds the maximum strign length |
| pargs | Basic command-line parser |
| pprint | Re-formats first two lines on file so columns are left justified and values are right justified |
| print_header | Print filenames and divider |
| usage | Print usage information and exit program |
justify
peek.justify(h, d, n, nr)Calculates the spacing for justifying to the right
max_string
peek.max_string(data)Given a list of strings, finds the maximum strign length
pargs
peek.pargs()Basic command-line parser
pprint
peek.pprint(headlist, data, linelength, fn)Re-formats first two lines on file so columns are left justified and values are right justified
print_header
peek.print_header(filename, length)Print filenames and divider
usage
peek.usage()Print usage information and exit program