I am not sure whether I understood your requirement.
You have a PI Point (Tag A) which is already collecting the data in PI Archive. You need one more PI Point (Tag B) which should have "1" as a value when Tag A has particular value.
For example, When Tag A is 95 then Tag B should be 1 otherwise no value should get stored for Tag B.
If my understanding is right, you can achieve this with "If...then...else" condition in PI PE or PI AF expression analysis. Once you have created it you can backfill the data for Tag B to get the history values depends on Tag A.
If my understanding is wrong, kindly elaborate your requirement bit more.
Thanks for your advice.
Request you to configure PI AF analysis and map it to AF attribute (not necessarily PI Point). Analysis data reference (output) attribute should calculate the count based on timestamp in PI Vision.
Thanks for your advice
1 of 1 people found this helpful
First, you can use an event triggered Analysis Rule to do filtering on your raw PI Point and output this to an intermediate PI Point.
If('tag' = 1) then 1 else NoOutput()
Then you can use another PI Point Data Reference with the Value Retrieval Method of "Count" to count the number of occurrence in the time range. Something like this.
When you use By Time: Time Range, PI Vision will be able to calculate on demand the count when you change the time range of the display.
2 of 2 people found this helpful
I found the "Count" method will miss some historian data when Backfilling data in AF analyses, it is strange.
I used "Total" instead of "Count" for calculation and found that no historian data missing(All Raw PI points value are either "0" or "1", so it works)
Great to hear, you got the solution Liang