Hi, PI Newbie here!!

I'm trying various methods to calculate the running total of numerous tags from current time to 30 days previous (the dates are changed to reflect 24 hours, 30 days 365 days etc)

So far I'm using;

tagtot('tagname','*-30d','*')

The start time is set as *-30d and the end time is set as current *.

Would this be the recommended method or is there an alternative?. The raw data the tags are reading contains electrical readings at 15 minute intervals and are received per hour.

The results I'm receiving seem to be providing an average over the last 30 days rather than a total?

Any help would be greatly appreciated

Hi Darren,

I believe tagtot you used should be from PI PE function. However, in the description of this function in PEReference, it says this function is used to "Find the totalized value

(time integral)of a point over a given time, according to values stored in the Archive." The red words, time integral, in the description means this function used time-weighted way to calculate total. If you need the event-weighted way to do the calculation, PI SDK / AF SDK function should be considered. Please see the help menu of PI SDK. The function is under PI DATA part named as Summary method.Please see the following code as the reference:

Xi Wang

v-Campus team