MinRunOverTime

This function returns the minimum of all values whose timestamps are greater than the newest timestamp minus the specified interval.

Syntax

MinRunOverTime ( number, valueTimestamp, interval)

Remarks

The number parameter specifies the data value for which the minimum is to be calculated. The valueTimestamp is the timestamp for this data value. (The Timestamp function can be used to obtain this timestamp.) The interval parameter is the time interval, in nanoseconds, over which to calculate the minimum. The predefined time constants can be used to easily input the number of nanoseconds in a microsecond (nsecPerUSec), millisecond (nsecPerMSec), second (nsecPerSec), minute (nsecPerMin), hour (nsecPerHour), day (nsecPerDay), or week (nsecPerWeek). The function will buffer any values whose time is within the specified interval. Any value that evaluates to –INF, INF, or NAN will be ignored. If no valid values have been considered, this function will return NAN.

Example

The following example will return the minimum value of the variable Temp_F over the past 30 seconds. (The StartRelativeToNewest function backfills the data set initially to the full 30 second interval, provided that the data is available in the data source.)

StartRelativeToNewest(30*nsecPerSec, OrderCollected); MinRunOverTime("Server:CR1000.Second.Temp_F",Timestamp("Server:CR1000.Second.Temp_F"), 30*nsecPerSec)