LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Histogram Miscount

Solved!
Go to solution

Guys,

 

I am trying to write a program that will count the number and magnitude of disruptions to a load cell and record that information in a histogram.  That data is then sent to an excel report for convenience of other users.

 

My problem is that if you look at the attached jpeg, (the waveform chart and histogram summarize the test) you can clearly see that there are only 4 disruptions.  Can someone help me figure out why my histogram says there is 5?

 

Thanks

Download All
0 Kudos
Message 1 of 6
(2,936 Views)

I noticed that

 

1. Your histogram range is 7-15 with 8 bins, but I have a peak between 6 and 7 (the first peak from left).  That peak will not be capture by the histogram. 

2. Is it possible that you have points between peaks and 5 that you are not aware of?  For example, the bin at 7, will contain all values between 7-8.  

 

I hope that help.

------------------------------------------------------------------

Kudos and Accepted as Solution are welcome!
0 Kudos
Message 2 of 6
(2,928 Views)
Solution
Accepted by topic author raging_engie

Hi raging_engie,

 

I believe that the confusion here is resulting from the way in which the histogram function works.

 

The histogram function does not count the number of peaks in a certain range, but the number of samples in that range.  It is a little hard to tell from your screenshot because the waveform graph is connecting samples with lines, but I believe that in one of your larger peaks, there is a sample in the 7-8 range.

 

Have a great day,


Chris V

Applications Engineer
National Instruments
0 Kudos
Message 3 of 6
(2,898 Views)

But shouldnt the fact that the historgram is only recieve the maximum positive peak data from the previous express VI take care of that problem?

 

0 Kudos
Message 4 of 6
(2,896 Views)

Put an indicator at the input of the histogram and show us exactly what is the data that you are plotting.  That should clear up confusion.  

------------------------------------------------------------------

Kudos and Accepted as Solution are welcome!
0 Kudos
Message 5 of 6
(2,871 Views)

I figured it out.  Thank you for everyone's help. It had to do with bin count but also with the the fact that the sampling rate was too fast for the buffer.

0 Kudos
Message 6 of 6
(2,859 Views)