cancel
Showing results for
Did you mean:

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Frequent Visitor

## Percentage of the total latest values

Hi!

This sound rather simple, but I cannot seem to make it work and it is very important for my project.

I have connected Power Bi to a live data stream and below I have a table representing the latest live stream values for each ID. The binary column tells wether the sensor's data fulfills certain requirements - 1 means it does and 0 that it doesn't. Now I need to calculate the percentage of the latest values that meet the requirements. For example in the table below the percentage would be 0% since all the latest values of each ID are 0.

I hope I have explained the problem clearly enough. Thanks in advance!

5 REPLIES 5
Frequent Visitor

So I have sensors sending temperature, relative humidity and pressure data at a frequency of 1Hz. I have added a measure to the table to check if the values are exceeding certain limit for each variable and if one or more limits are exceeding the measure gives value 0. In turn, if all values are below the limit, the measure gives value 1.

What I need is to check how many percent of sensors are currently showing satisfactory data (=1) thus only the most recent data is relevant. So I just want to count the number of sensors giving value 1 and divide them by all values, however I don't know how to combine the LASTNONBLANK with COUNT function.

Helper II

could you give us a more detailed example of what you have and expect to have?

Frequent Visitor

I now a system containing dozens of sensors sending real time data to the cloud. I analyze the data using Azure functions and Power Bi.

One of the function I need to have is real time percentage information showing how many sensors are currently OK.

Super User

What is the definition of latest values?

Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤

Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

Frequent Visitor

The latest values are the most recent values of each sensor.

Announcements

#### Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.