addSparseReactiveMetrics
Syntax
addSparseReactiveMetrics(name, metrics)
Details
Adds sparse state computation rules to the specified SparseReactiveStateEngine. The
format of the new metrics is the same as the metrics parameter of
createSparseReactiveStateEngine.
Parameters
name is a STRING scalar indicating the name of the SparseReactiveStateEngine to which rules are added.
metrics is a table representing the set of rules to be added. Its schema is
the same as the metrics parameter of
createSparseReactiveStateEngine: keyColumn(s), formula,
outputMetricKey.
Returns
Returns no value or returns an execution status (subject to the actual product implementation).
Examples
newMetrics = table(
["A003"] as deviceID,
["mavg(value,3)"] as formula,
["A003_1"] as outputMetricKey
)
addSparseReactiveMetrics("demoengine", newMetrics)
Related functions: createSparseReactiveStateEngine, getSparseReactiveMetrics, deleteSparseReactiveMetric
