LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Variance of 20 Samples At a Time....

Solved!
Go to solution

You need to change the format string to %s for strings.

 

Have you worked through the tutorials?  Some of the problems you are having are fundamental LV concepts. Spending a few hours learingthe basics will save you much more than that in just the next few weeks.

 

Lynn

0 Kudos
Message 11 of 18
(909 Views)

To be honest I've not looked at LV tutorials on the subject because I know how to save numerical data to spreadsheet so I thought it'll be much of the same; I guess it's not. In my vi I pass an array of strings (each time stamp is an entry), and changing the format to '%s' didn't work nor I think it's what I need. 

 

Thank you for the input though, I'll definitely spend some time this weekend on LV tutorials. 

0 Kudos
Message 12 of 18
(902 Views)

Connecting string arrays after each case/loop, it seems that I don't output any entry in my array....

0 Kudos
Message 13 of 18
(901 Views)

Please post what you have tried.  It is almost impossible to guess what you are doing and why it does not work.

 

Lynn

0 Kudos
Message 14 of 18
(898 Views)

Here is the latest one.

Thank you for taking a look at it.

 

 

0 Kudos
Message 15 of 18
(890 Views)
Solution
Accepted by topic author simply_me

I do not understand all of your logic (thresholds and timing), but it seems to work for me.  I get very few points, so maybe that is where the problem is located.  Do you see data on the Time String array indicators and not in the file?

 

I cleaned up the diagram and reduced it to fit on my screen.  I eliminated the extra build array after the while loop and used the 1 D array input.  Index Array rather than a 1-element array subset and used scalars directly for comparison rather than dynamic data.

 

Generally use of Build Array in a loop is not good practice if the arrays may get large because it requires repeated memory reallocations.  Initialize the array outside the loop and use Replace Array Subset.

 

Lynn

Message 16 of 18
(883 Views)

Hi Lynn,

 

Well, I want to implement this vi in a larger vi that does particle tracking/analysis, so to define a "jump" I collect a set of FPS/2 data points , check variance, and then differential if it's needed. It is important to time stamp the jumps in order to get characteristics. 

This vi implements the algorithm I use and works in the same manner as the functional requirements for the main vi, I just created this one for simplicity (without including IMAQ and other algo). 

I didn't know that build array in a loop recopies the entire array each time, I guess I"ll have to change my habits 🙂 I'll do the changes you've suggested. 

Thank you for your explanations & help, it seems to work great now. 

0 Kudos
Message 17 of 18
(877 Views)

Hi Lynn,

 

Well, I want to implement this vi in a larger vi that does particle tracking/analysis, so to define a "jump" I collect a set of FPS/2 data points , check variance, and then differential if it's needed. It is important to time stamp the jumps in order to get characteristics. 

This vi implements the algorithm I use and works in the same manner as the functional requirements for the main vi, I just created this one for simplicity (without including IMAQ and other algo). 

I didn't know that build array in a loop recopies the entire array each time, I guess I"ll have to change my habits 🙂 I'll do the changes you've suggested. 

Thank you for your explanations & help, it seems to work great now. 

0 Kudos
Message 18 of 18
(876 Views)