I am developing one application in labview in which i need to measure the temperature sensors data coming from three different channels & average them. This thing need to be done for another set of three temperature sensors.
Then i need to find out the difference in mean temperature of these two groups. (One group means three temperature sensors)
Please suggest how should i incorporate this. (Should i try to use array or developing one vi to measure signal coming from three sensors & then use it as sub VI in another program where i can use it twice for two groups & then find the difference)
The general rule of thumb is that if you're doing the same thing in more than one place, then one should reconsider making the repeated code into a subVI. As far as where to break it down ... that depends. You could have a subVI that acquires the readings and returns the array of readings. Whether or not this subVI returns a mean is more of a convenience issue. There's already a Mean VI that can be used for an array of values. So, if your subVI returned just the array you could plop it down twice and then use the Mean VI to get the mean of each group, and then use it again to get the mean of the groups. If the subVI already returned the mean (implying that bit of code is inside the subVI), then you would just be getting the mean of the groups.