2.2.27. addCalculation
Purpose
Add or alter column(s) with derived values according to user-defined arithmetic operation between column(s). Column labels are tagged by '#label#' in formulas. Use ';' for ',' in functions. Numpy is available as 'np'. Special variables: #_row_# -- row index Examples: (1) magnitude of vector -- "np.linalg.norm(#vec#)" (2) rounded root of row number -- "round(math.sqrt(#_row_#);3)"
Usage
> addCalculation options ASCII table(s)
Options
-
-l
/ --label
- (list of) new column labels
-
-f
/ --formula
- (list of) formulas corresponding to labels
-
-c
/ --condition
- condition to alter existing column data (optional)
Examples