LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Average

Average,

Is there, or is it possible to make subVI with
- One input
- One output
- The output gives the average / mean value of the last n (constant or
variable) value's on the input.
- It's no problem that the first n output values are incorrect.
- It's a problem when the input is a subVI in the loop or program.

Thanks Paul
0 Kudos
Message 1 of 3
(2,512 Views)
Paul;

Unless "n" is a constant value or depend on the number of elements on the input array, you need an extra input to tell your subvi where to split the array.

You can explit an array using the "Split 1D Array" vi, located in the Array menu in the functions palette.

You can use the "Mean" vi located in:

Mathematics -> Probability and Statistics

With this, certainly you can do what you want.

Regards;
Enrique
www.vartortech.com
0 Kudos
Message 2 of 3
(2,512 Views)
"You can explit an array..."

Sorry, I mean split...
www.vartortech.com
0 Kudos
Message 3 of 3
(2,512 Views)