- Print
- DarkLight
- PDF
The numeric-slice parser will evaluate or load data from a single column in comparison with a numeric constant value. Depending on the value of the operator attribute, the column's data will evaluate to true, false, or null.
It inherits attributes and behaviors from its parent: abstract parser - boolean.
Note - in the case where a numeric-slice parser is used to create a categorical variable - it is usually a better option to use a numeric-map parser instead - especially to avoid needing multiple numeric-slice parsers to map all data cases from a column into different variables.
Attribute - operator
The operator attribute is required.
{
"parser_type": "numeric-slice",
"column": "cccc",
"value": ####,
// The operator attribute defines a comparison function.
// Options include:
// "=" - equals
// "!=" - not equals
// "<" - column value is less than the constant value
// "<=" - column value is less than or equal to the constant value
// ">" - column value is greater than the constant value
// ">=" - column value is greater than or equal to the constant value
//
"operator": ">"
}
Attribute - value
The value attribute is required.
{
"parser_type": "numeric-slice",
"column": "cccc",
"operator": ">",
// The value attribute defines a constant value against which
// the parser will evaluate dynamic values from the column.
//
"value": ####
}