LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Storing values to get an average.

Hello there. I'm trying to store some values that my program is getting from a digital multimeter (Agilent 3458A). What I want to do is to have an average of the readings I'm taking in a period of time. The program is running with a while loop, so what I want to do is to store the values that the program gets for each run, add them up and then divide them by the number of times the program ran so I can get an average. I don't know, maybe there is a better way to do this? But at least for now I would like to know if I can store thos values with a function, maybe an array or something.
0 Kudos
Message 1 of 2
(2,659 Views)
You just need a shift register. A great example that displays a running mean is here.
Message 2 of 2
(2,650 Views)