11-05-2016 01:31 PM
I want to do the following steps:
1. Read from a text file and convert it to an array.
My text files are with 2 colums, like this:
1 1053
1.3 1044
1.5 2033
1.7 2444
1.9 4335
2. Extract a range of data points from that array.
I wanna give it an order to extract the data points that I want and output as an new array.
The range starts when colum 1 value > 1.2, and end when colum 1 value < 1.8. (1.3 to 1.7)
And extract the range of data from these two colums, so my expect result array is:
1.3 1044
1.5 2033
1.7 2444
Can anyone help me?
I'm a new user of labview haha, Thanks a lot!!!!
Solved! Go to Solution.
11-05-2016 02:15 PM
"Read from spreadsheet file" (or "read delimited spreadsheet" for newer LabVIEW) will get you the data as a 2D array.
(Your post does not show the delimiter between entries. Is it a space or a tab character?)
To get a subset, use "array subset".
11-05-2016 02:20 PM - edited 11-05-2016 02:21 PM
altenbach 已寫:"Read from spreadsheet file" (or "read delimited spreadsheet" for newer LabVIEW) will get you the data as a 2D array.
(Your post does not show the delimiter between entries. Is it a space or a tab character?)
To get a subset, use "array subset".
Thanks for ur quick response!
Do you mean the separation of colum 1 and 2 in the text file?
The separation between colume 1 and 2 in the text file is like this.
Thanks!
11-05-2016 05:38 PM
@Ying88827 wrote:
The separation between colume 1 and 2 in the text file is like this.
OK, your column seperator is the tab character. This is the default, so you don't need to wire it.
11-06-2016 01:58 AM - edited 11-06-2016 01:58 AM
Again you still have not mentioned your LabVIEW version, but here's one simple solution.