From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to count certain number of boolean values in array?

Solved!
Go to solution

I have a boolean array and want to find all the false values in the array. I then want to count how many of those false values are in the array and determine if that is <1% of the total values. Any suggestions on how to do this?

0 Kudos
Message 1 of 3
(940 Views)

Duplicate

Rolf Kalbermatter
My Blog
0 Kudos
Message 2 of 3
(931 Views)
Solution
Accepted by LearningLabVIEW

Pass the Boolean Array through a "Negate" and then a "Boolean To (0, 1)" Node and the resulting array into an "Add Array Elements" node. I'm sure you can do the percentage calculation yourself.

Rolf Kalbermatter
My Blog
0 Kudos
Message 3 of 3
(929 Views)