Our full technical support staff does not monitor this forum. If you need assistance from a member of our staff, please submit your question from the Ask a Question page.


Log in or register to post/reply in the forum.

Latest record in RTMC Pro


Otemohu Mar 22, 2018 08:50 PM

Hi,

I would like, for a check, to be able to take the latest value of the table minus the one recorded just before in the table. Is there a way to do that?

All the best,


JDavis Mar 22, 2018 09:47 PM

If you look in the help in RTMC in the topic of Expressions, it gives an example of doing exactly what you want.


Otemohu Mar 23, 2018 07:42 AM

Hi JDavis,

Thank you for your quick reply but I didn't found what I need.
It is not clear for me. I thought first using Last() function but it seems not running properly. Maybe can I use StartatOffsetFromNewest but it seems not appropriate cause I need only one value, the value at record n-1.

Best


jtrauntvein Mar 23, 2018 07:03 PM

If the result of you expression needs to be the difference between the current record less the value from the previous, you will, by definition, need to reference more than just the current record and the StartAtOffsetFromNewest(2, OrderCollected) modifier is absolutely appropriate.  The Last() function does not magically conjure the data.  All it does is to store the current value and return the previous value.


Otemohu Mar 23, 2018 09:00 PM

It is still unclear for me. What I understant is that StartAtOffsetFromNewest is just used to "collect data" from the record number we want, eg the last 2, 3, ...100 latest values. And then we can make calculation on all the dataset collected by StartAtOffsetFromNewest function? But if for example I want to display the record number n-1, how can I manage this ?!?
With the following function, it does not work :
StartAtOffsetFromNewest(2, OrderCollected);
"Station:Table.Variable_Avg"
This display the same as just "Station:Table.Variable_Avg"

What I want is finally "Station:Table.Variable_Avg" at record number n minus the "Station:Table.Variable_Avg" at record record n-1


Otemohu Mar 23, 2018 09:37 PM

Oh excuse me, I unstertood now:
StartAtOffsetFromNewest(2, OrderCollected);
Last("Station:Table.Variable_Avg")

And now, what about a table for which, at each time I want through a period of 5 days for example, all the displayed data are the difference between data(n) and data(n-1)
If I want for example a table or a graphic with:
data(n)-data(n-1)
data(n-1)-data(n-2)
data(n-2)-data(n-3)
....

Is it possible ?

I think I begin with StarAtOffsetFromNewest(5*48,OrderCollected) to have 48 half-hourly values from the last five days...


Otemohu Apr 12, 2018 09:36 AM

Hello everyone,

Has someone a solution to my issue? I've tried to go forward but without success....

Best,


Otemohu Apr 19, 2018 07:00 AM

Anybody with ideas?

Log in or register to post/reply in the forum.