Time period sum (TPS#)

Time period sum (TPS#)

This calculates the sum of values for a series for full calendar periods between the display start and end dates. The calendar periods are calculated from the start date Incomplete periods are ignored and filled with nulls ('N/A'). The TPS# function is similar to the calendar sum functions, but offers greater flexibility in your choice of time period. For example, if you specify a mid-month start date, TPS# calculates a series of sum values for consecutive mid-month to mid-month periods.Unlike a moving format SUM# function, TPS# periods are consecutive and do not overlap.

Format

TPS#(Expression,Period,Parameter)

Where Period is a time period of one or more full calendar days, weeks, months, quarters, or years. The trailing and optional parameter can only have value N which means that a time period containing a null value will produce null values as output.

Example

TPS#(U:IBM(VO),1W)

This calculates the total trading volume for IBM (000's of shares traded) for each calendar week between the start and end dates of the display period. If the screen specifies a one year display, this example will return 52 values. Any days at the end of the display within an incomplete week are filled with null values ('N/A').

See also

Sum functions