Loading

reducer.and


reducer logic
Since v1.0.11
Available on all platforms
See also

The reducer.and function outputs the result of the logical operator AND for each tick value of Geo Time Series™ which are in the same equivalence class.

The location and elevation returned are the first one encountered, which may vary depending on the order of the parameters.

The reducer.and function can be applied to values of any type, when not applied to BOOLEAN types, the current value is considered to be false.

The standard version of this reducer, reducer.and, will return null for any tick where one or more GTS have null values. The exclude null version, reducer.and.exclude-nulls, will exclude all null values when computing the AND.

Signature

Examples

[ NEWGTS 'test' RENAME { 'label0' '42' 'label1' 'foo' } RELABEL 100 NaN NaN NaN true ADDVALUE 200 NaN NaN NaN false ADDVALUE 300 NaN NaN NaN true ADDVALUE 400 NaN NaN NaN false ADDVALUE 600 NaN NaN NaN true ADDVALUE 800 NaN NaN NaN true ADDVALUE NEWGTS 'test' RENAME { 'label0' '42' 'label1' 'bar' } RELABEL 100 NaN NaN NaN true ADDVALUE 200 NaN NaN NaN true ADDVALUE 300 NaN NaN NaN true ADDVALUE 400 NaN NaN NaN false ADDVALUE 500 NaN NaN NaN false ADDVALUE 700 NaN NaN NaN false ADDVALUE ] [ SWAP [] reducer.and ] REDUCE