Now, you can save your searches to easily repeat search requests.
Saving a search is as easy as 1-2-3:
1. Perform a search. The Search Results page opens. 2. Optionally, choose filters or update your search term. 3. Click Save Search.
You can access saved searches from a list next to the Search field that appears on every page. Saved searches store the search term and any search filters that you apply.
You want to compute average temperature of cities in a region. Add an Expression transformation to your streaming mapping.
Configure the following ports in the transformation:
city. Input port of string data type.
temperature. Input port of double data type.
avg. Output port that displays the average temperature.
count. Variable port of integer data type with expression ‘count+1’.
average. Variable port of double data type with expression (average * (count-1) + temperature/(count)
You partition the data by "city". The "average" corresponds to previously stored value for the "average" and is computed with each update in the value of "count". Since "count" is already incremented when "average" is evaluated, specify "count-1" in the expression to get the new average.
The following image shows an Expression transformation: