Jump to content

Top 5 Items By Count & Duration


Go to solution Solved by Joanna Zinsli,

Recommended Posts

I am trying to figure out how to create a table that shows the Top 5 machine alarms by count for the last X hours and another table that shows the Top 5 machine alarms by duration for the last X hours. Ideally the table would look similar to what I have sketched out below. I have a continuous discrete signal that is the active alarm on the equipment. So I can create a Condition with Properties that has the alarm description as a capsule property. I now need to count the alarm capsules by description and then rank them from highest to lowest. 

Any help/suggestions on approach would be appreciated. 

image.png.70928dcb2c3361af3888f0e3fc27ff91.png

Link to comment
Share on other sites

  • Seeq Team

Hi Lucas,

In a future version of Seeq, pivot table functionality will enable you to easily create the tables you want, and you could do a table sort to see the top 5, but it would not quite allow you to filter to only the top 5. 

In the current version of the software, here are some options to consider, depending on the details of your analysis and how many different types of machine alarms are possible. 

1. You could use the Histogram tool in Workbench, along with your condition with properties that has the alarm description as a capsule property, to create count of alarms and duration of alarms histograms. This would be very quick/easy to do, but will of course show ALL alarms that have occurred and without pareto sorting, and the results are not in tabular form. 


2. If the number of potential alarm descriptions is relatively low and you don't expect new descriptions to be added in the future, you could manually create conditions representing each unique alarm description (via the .keep() function in Formula, using your existing condition with properties). Then you could create a table of counts and a table of durations for each of the created alarm description conditions, sort the table, etc. It will not limit the table results to the top 5, but you could filter the table based on count and duration to limit the rows displayed. 

3. Pull the alarm signal into Seeq Data Lab using the Spy.pull() function, and create your desired tables using Python code. 

Link to comment
Share on other sites

Thanks for the information John. This is helpful context for my use case. Do you know which upcoming Seeq version will contain the pivot table functionality? As far as the current options you presented, here are my thoughts:

  1. I have used the Histogram tool approach and it does allow me to show relative bucket size by count/duration. Like you mentioned, it does not allow for sorting into a pareto view. Being able to sort the histogram would be very close to what I am trying to accomplish. One issue I ran into is the alarm messages are truncated on the histogram x-axis.
  2. Unfortunately, I have a large amount of alarms and that list is dynamically adjusted according to various business scenarios. 
  3. I think this is my best potential approach. I thought I would ask before pursuing a Seeq Data Lab solution. 

One unrelated question: could the transform() Formula tool be a potential approach. I notice in its documentation that it mentions, "Get the first capsule of $condition in each week. If there are weeks that don't have any capsules in them, the resulting condition will be empty during those weeks."

Thanks again for your help!

Link to comment
Share on other sites

  • Seeq Team
  • Solution

Hi Lucas,

Table grouping and aggregations will be available in R64, to release in a few weeks. You can read more about the capabilities at these pages https://support.seeq.com/kb/latest/cloud/what-s-new & https://support.seeq.com/kb/latest/cloud/tables-charts#id-(R64)Tables&Charts-GroupingandAggregating. I think this will fit your needs well to have a table of capsules with each failure, then group by the failure column. You can aggregate a count or sum all the capsule durations when you've grouped.

There's also an alternative Dashboard interface in Organizer in this upcoming release. While you cannot yet limit the table to top 5 (or N), tables inserted in Organizer Dashboards have a max height. This means you could configure it so that only 5 rows show and viewers can scroll to see the other rows (or not if not relevant). You can see that on the What's New page linked above or read more at https://support.seeq.com/kb/latest/cloud/inserting-content-dashboards 

I do not expect transform() to help in the mean time. The transform() function is used to create a new signal or condition by applying a transformation to each element of an input series, such as a signal or condition. It operates on individual samples or capsules and does not provide aggregation capabilities like counting. My guess is it would be great to grab individual capsules but might be very complicated, if not possible, to group by properties and extract information that way.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...