01-16-2009 02:01 PM
I would like to be able to manipulate some data (columns 2 and 3 of txt file) that I am collecting as a function of time (column 1 of txt file).
Right now, as the VI is running, this data is being plotted on a waveform chart and saved to txt file.
What I need to do is:
Column 1 - Convert each time point to a wavelength. I know starting wavelength (nm) and rate of change of wavelength (nm/sec). I do this conversion on an excel spreadsheet right now where [current wavelength = previous wavelength - rate of change of wavelength*(current time-previous time)]. So how do I extract column one, take the difference between the second value and the first value, and create a new column (somewhere) corresponding to wavelength? And save to a new column?
Column 2 - Need to divide each value by 100 and subtract by a "baseline" (an average of the first 20 points, for instance).
Column 3 - As is.
Final step - Write to file a new column defined as manipulated column 2 divided by column 3 times 100...and then plot this (on y-axis) as a function of manipulated column 1 (x-axis).
It's not incredibly critical that the data manipulation occur in real-time...it can happen after the file has been written if necessary. The final graphical result should look like the attached jpeg.
Thanks in advance for the help - I'm a little uncertain about array conversion, unbundling, etc. nevermind the mathematical differences and averages that need to be obtained.
Meredith
Solved! Go to Solution.
01-16-2009 09:06 PM
hello,
i tried to make what i understood , see if it make sense
few textual details in vi, two jpg attached in case your 're not LV8.6
look at xy result to see if that talk to you , not for me
Best regards
Tinnitus
01-19-2009 12:10 PM
Tinnitus -
I've worked through this and it looks like it does exactly what I need to do. It's taken me some time, as I don't have LabVIEW 8.6.
I've been able to replicate everything except the "Directe" going into the dt of the derivative function. Where can this be found on the LabVIEW control or tool palette?
I appreciate your help - I knew I would need to use some of the array functions, but I was unsure exactly how Index Array, Array Subset, etc. should be implemented.
After I get the dt input, I should be able to test it with the data myself.
Meredith
01-19-2009 01:01 PM
hello,
just make a right click on method ( blue terminal) at the bottom of derivate block and selecte create -> constante
then make a choice in ring menu,
@+
Tinnitus
01-19-2009 01:10 PM
Am I maybe using the wrong derivate block? Jpg attached of what I'm using.
It only has one blue terminal, and that's the error output. This is from Mathematics -> Integration and Differentiation.
That could explain why I wasn't finding anything similar.
01-19-2009 01:16 PM - edited 01-19-2009 01:23 PM
You are using the correct VI
This is as the VI appears in 8.6.
01-19-2009 01:17 PM - edited 01-19-2009 01:18 PM
hello,
??? maybe an evolution between 8.2 and 8.6
1) try to slide your mouse over block diagramme to see if it is not just a neglect display
2) try without this option perahaps "direct" "forward" methode is the only one used in your release...
@+
Tinnitus
01-19-2009 01:21 PM
01-19-2009 01:21 PM
I saw
just a error of translation :
"forward" equal " direct" in french
Regards
01-19-2009 01:29 PM
Maybe check the actual VI by double clicking on it.
It should appear like this:
on the block diagram.
If not, see if you can wire up an input manually.