Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
titleExample for map operators with temporal attributes
/// Energy consumption per household per minute in the next 15 minutes
derivative = MAP({
	expressions = [
		['derivative(temp_wh, PredictionTimes)','whPerMinute'],
		['id','id']
	]           
},predTime)
              
/// Energy consumption per household per minute in the next 15 minutes
watts = MAP({
	expressions = [
		['whPerMinute * 60','watt'],
		['id','id']
	]           
},derivative)

Select
Anchor
Select
Select

The select operator works a little different when a temporal attribute is involved in the predicate (i.e., an expression with Boolean return value). It does not tell if, but when a stream element fulfills the predictate. It does this by reducing the prediction time interval(s) to the intervals in which the predicate return true. If the prediction times are empty, i.e., if the predictate is not true at any point in time in the incoming prediction time interval(s), the stream element is removed completely.

...

Code Block
testSelect = SELECT({
	predicate = 'tdistance > 15000'                
},calcDistance)
              
testTrim = MAP({
	expressions = ['TrimTemporal(tdistance, PredictionTimes)']
},testSelect)

Join

TextWhen applying a join operator on two streams with PredictionTimes metadata, the operator intersects the PredictionTimes to create the result element. The predicate is handled equally as in the select operator.

Aggregate

Text

Examples

Text