name: "clipivot"
about: "A tool for creating pivot tables from the command line.
\nFor more information, visit https://github.com/maxblee/clipivot"
settings:
- ArgRequiredElseHelp
args:
- aggfunc:
help: "The function you use to run across the pivot table.
\nThe functions fit into three main categories: numeric, textual, and type-independent.
\n- Numeric functions parse records as numbers, raising an error if it can't identify a number.
\n\t- mean computes a mean across the matching records
\n\t- median computes the median of the matching records
\n\t- stddev computes the sample standard deviation of the matching records
\n\t- sum sums the values
\n- Textual functions parse everything as text
\n\t- count counts all of the individual records; it operates independently from the values
\n\t- countunique counts all of the unique records.
\n\t- mode determines the mode (the most commonly appearing value), in insertion order in the case of a tie
\n- Type-independent functions have a default parsing method that can be overridden with the -i or -N flags
\n\t- max computes the maximum value. Defaults to strings (mainly for YYYYMMDD HHMMSS date formats)
\n\t- min works identically to max but for computing the minimum value (or oldest date)
\n\t- range computes the difference between min and max. Only works for valid numeric and date formats.
\n"
required: true
index: 1
possible_values:
- count
- countunique
- max
- mean
- median
- min
- mode
- range
- stddev
- sum
- filename:
help: The path to the delimited file you want to create a pivot table from
index: 2
- rows:
help: The name of the index(es) to aggregate on. Accepts string fieldnames or 0-indexed fields.
long: rows
short: r
takes_value: true
multiple: true
- columns:
help: The name of the column(s) to aggregate on. Accepts string fieldnames or 0-indexed fields.
long: cols
short: c
takes_value: true
multiple: true
- format:
help: The format of a date field (e.g. %Y-%m-%d for dates like 2010-09-21)
short: F
takes_value: true
- value:
help: The name of the field you want to apply the aggregation function to.
long: val
short: v
takes_value: true
required: true
- numeric:
help: Parses the type-independent functions as numbers
short: N
- infer:
help: Infers the type/date format of type-independent functions
short: i
- empty:
help: Ignores empty/null values (e.g. "", NULL, NaN, etc.)
short: e
- noheader:
help: Used when the CSV file does not have a header row
long: no-header
- delim:
help: The delimiter used to separate fields (defaults to ',')
short: d
long: delim
takes_value: true
- tab:
help: Fields are tab-separated (equivalent of setting delimiter to '\t')
short: t
- dayfirst:
help: In ambiguous datetimes, parses the day first. See https://dateutil.readthedocs.io/en/stable/parser.html for details.
long: day-first
- yearfirst:
help: In ambiguous datetimes, parses the year first. See https://dateutil.readthedocs.io/en/stable/parser.html for details.
long: year-first
- indexcol:
help: Displays column names in index order (i.e. the order in which they appear)
long: index-cols
short: I
- desccol:
help: Displays the column names in descending sorted order (default is ascending)
long: desc-cols
short: R
- ascrow:
help: Displays the rows in ascending order (default is index order)
long: asc-rows
short: a
- descrow:
help: Displays the rows in descending order (defaul is index order)
long: desc-rows
short: D