Returns the mean value in an Observation's buffer.
This function is available in firmware 3.1.0+.
Parameters
Parameter | Type | Required | Description |
---|---|---|---|
obs_name | String | Yes | The name of the Observation from which to get the mean value from the buffer. |
windows_time_size | Integer | No | The time window, in seconds, is the time from which to begin analyzing the data. |
Returns
The resulting data will be a scalar, or null
of the buffer is empty.
Example
Request
var result = Observation.getMean('light', 10);
Response
890