LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Need help as a beginner

Solved!
Go to solution

Hello, sorry for the question that may be a silly one for experts. Actually i am reading a text file consisting of several columns and more than 200 thousand rows. I have to plot this data as XY plot. But when i plot the data, the system  becomes very slow and i to wait for further actions when i analyse the plot. Is there any way to overcome this issue?

0 Kudos
Message 1 of 9
(2,602 Views)

There really aren't enough pixels on your xy graph to reasonably show all that data, meaning your approach is bad. I would use an intensity graph and map the data into the pixels at a reasonable resolution and fixed number of grid points.

 

How does the data look like? What kind of interpolation are you using? What is the datatype of the xy graph? Can you give a simplified example and data?

0 Kudos
Message 2 of 9
(2,587 Views)

Thank you for your reply. i would like to post my VI and the sample text file. 

0 Kudos
Message 3 of 9
(2,572 Views)
Solution
Accepted by topic author Hussam_KUT

Hi Hussam,

 

  1. read your file
  2. strip first and last row (as this greatly hurts in the conversion step!)
  3. then convert the remaining rows to usable numbers
  4. then decimate that number array

Like this:

check.png

Now LabVIEW is still "usable" even when displaying your data…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 9
(2,566 Views)
Solution
Accepted by topic author Hussam_KUT

Sorry, I just had a change to look at your VI right now and I am truly horrified.

 

Can we take a step back and try to figure out what you are actually trying to show and what's interesting in that dataset. Decimation as suggested by others is a lossy operation so I am not sure it is appropriate, but it is also definitely not appropriate to push way more data that ever can be seen into an xy graph.

 

  • Once you eliminate the local variable (=wire from the "all rows" directly to the place where the local is), your sequence structure can be eliminated.
  • All your data is spaced equally in x, so a plain waveform graph is all you need, significantly reducing the complexity of the data structures.
  • There is a +1 primitive and the two first FOR loops are just plain silly. I am sure there is a way to calculate a new integer from another integers much more directly. No need for any orange or loops or to update the indicators during the loops..
  • To create an integer ramp, there is no need for shift registers and such. Still, you don't even need it because you don't need xy graphs.

So I recommend a little more thinking for the entire thing. See how far you get. Most data seems quite constant over time and is mostly noise.

0 Kudos
Message 5 of 9
(2,538 Views)

Hi, thank you for your kind response. I have skipped first rows and last rows but still have the issue when i plotting the all the data, the program becomes slow. can you share this sample VI?

0 Kudos
Message 6 of 9
(2,513 Views)

Hi, thank you for your detailed reply,

  • Ok, I removed the local variable and directly connected the wire.
  • I didn’t understand what kind of graph I have to use for this data to plot.
  • I am finding mean and standard deviation of this data. First I am reading the data and then plotting it to analyze where the data becomes stable. The first for loop I have used for number of columns and rows to skip. The 2nd for loop I have used for the x-axis because in the data I don’t have time to plot the data.
  • What kind of graphs I need to plot this data? Can you help me please.
0 Kudos
Message 7 of 9
(2,509 Views)

Can you define what "becomes stable" means? What is the "instability" and how do you recognize it? How many points are typically involved in the "instability"? You have so much data that a few outliers won't really hurt any mean/SD, and if they do, you can just ignore them based on some criteria.

 

If you are just looking in a drift of a rolling mean, you can massively reduce the data to be plotted. You probably could even detect it automatically, without any need to plot anything. It's just data analysis. So what is the plot for?

 

 

0 Kudos
Message 8 of 9
(2,479 Views)

The data varies with time, specially in column 7 which is temperature data.  At certain time the temperature becomes constant. Till that point or time i have to ignore the first data.

Next i have to find the mean and standard deviation of usable data and then have to find the allan variance plot too. 

Allan varian plot program is not yet available. I have to make too.

 

0 Kudos
Message 9 of 9
(2,455 Views)