Subtract¶
fast step math
Subtract two or more numeric columns.
An additional constant may be used to subtract from the final result.
Usage¶
The following are the step's expected inputs and outputs and their specific types.
subtract(*columns: number, {"param": value}) -> (result: number)
where the object {"param": value}
is optional in most cases and if present may contain any of the parameters described in the
corresponding section below.
Example¶
To subtract column number2
from column number1
:
subtract(ds.number1, ds.number2) -> (ds.difference)
More examples
To subtract the constant 1.23 from column num_col
:
subtract(ds.num_col, {"constant": 1.23}) -> (ds.difference)
Inputs¶
*columns: column:number
One or numeric columns to subtract (in left-to-right order).
Outputs¶
result: column:number
Numeric column containing the result of the subtraction.
Parameters¶
constant: number
A constant to subtract from input data.
ignore_nans: boolean = False
Whether to ignore NaNs or propagate them.