LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Read Text row by row, plot them and find the max of its Power spectrum

Hi, everyone,
 
I have to read data from a text file, plot as a time serie and find the frequency to its max power spectrum. I found a previous post related to my issue so I revised his example a little bit. But once I decide to store the data into an array, the Labview reported:' Error 1 occurred at Scan From String (arg 1)'. Can anyone help me out?
 
Thanks in Advance!
 
Gab
0 Kudos
Message 1 of 5
(3,311 Views)

Hi Gab,

the error pops up because the last two lines are empty. I have modified your vi. See the attachment please. Hope it helps.

Mike

0 Kudos
Message 2 of 5
(3,290 Views)

How come my reply to this in the morning NOT got posted... ?!Smiley SurprisedSmiley Mad

Hi Gab,

You can simply insert a Trim Whitespace after the string & get the job done. This is what I posted then.

- Partha ( CLD until Oct 2027 🙂 )
0 Kudos
Message 3 of 5
(3,275 Views)
Again my attachment got missed out. Smiley Sad
- Partha ( CLD until Oct 2027 🙂 )
0 Kudos
Message 4 of 5
(3,273 Views)

Guys, thank you all so much! Smiley Very Happy

Finally I used a Trim WhiteSpace.vi to fix this. But Mike's solution is more useful if I want to identify special character from the string.

Regards,

Gab

 

0 Kudos
Message 5 of 5
(3,238 Views)