-
Notifications
You must be signed in to change notification settings - Fork 9
Functions
liamjjmcnamara edited this page Oct 9, 2014
·
3 revisions
Streams can be populated be processing functions of other streams. For example, a stream may be formed from the mean of other input streams. Whenever a data point is added to one of its predefined input streams, the most recent value is taken from each input and the mean of them all is taken.
The current predefined functions are:
- mean
- median
- min
- max
To register a stream that is populated by a function, simply POST a new stream representation to SicsthSense in the following format:
{"function": "median", "antecedents": ["1", "2"]}
This should be POST'd to an URL of an already defined Resource in the form: http://HOST/users/X/resources/X/streams