LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Labview plots

Solved!
Go to solution

Hello, I'm new to labview and i have a problem with labview WaveformChart.

I need to plot all data sets to one plot but all data sets ends it's calculation right before WaveformChart in for loop so the end result is 1D array. and when i'm trying to print it to Waveform chart with for loop it leaves only last printed dataset. How can i change this?

0 Kudos
Message 1 of 15
(2,311 Views)

Maybe others on this forum are better than me... but I'm not visualizing what you're actually doing in the code here.

 

Please post your code or a mockup showing what your problem is and we can go from there.

0 Kudos
Message 2 of 15
(2,308 Views)

Yes, we need actual code here to be sure, but this sounds like a classic example of the difference between a "graph" and a "chart" in LabVIEW.

 

A "chart" has internal history/memory, so it takes what you send it and adds it to what it had before (up to a limit).  A graph takes what you send it and only shows the most recent values sent.

 

The "lazy" way to do this would be to get a history property node for the chart and use that.

 

The "proper" way would be to maintain the array of data you want manually and get that, instead of relying on a chart.

Kyle97330_0-1646344781028.png

 

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

If you have a fixed dataset, you need a graph, not a chart.

 

Please attach a simplified version of your VI so we can give more specific advice.

0 Kudos
Message 4 of 15
(2,279 Views)

Hello, here you have it. It has dataset from measurements with accelerometers. Each accelerometer has 3 axis and there were 4 of them. I need to plot all of them in a specific way. Each accelerometer axis has to be printed to the same plot area. And each accelerometer has to have personal plot area with all 3 axis. 

I want it to be controlled automatically to recognize that how many accelerometers has been uploaded and create as many plots area as a amount of accelerometers. 

0 Kudos
Message 5 of 15
(2,249 Views)

I've posted code. Thank you!

0 Kudos
Message 6 of 15
(2,246 Views)

Hello, thank you. I've posted code for you to better understand the problem. 

0 Kudos
Message 7 of 15
(2,245 Views)

Most people here don't use dynamic data and express VIs. Too opaque and too much overhead.

 

Apparently, you have an array of dynamic data and each array element contains three signals. Notice that you have an array of dynamic data, but your output tunnels throws everything away except the last filtered array element.

 

It is not clear what you want? (append the four array elements? Create four graphs, each with three plots? Something else?)

 

You definitely want a graph, not a chart.

 

Maybe something like this?

 

altenbach_0-1646382832531.png

If you want the number of graphs to adjust automatically, there will be some limitations, but it's doable.

Message 8 of 15
(2,221 Views)

@IlyaChaban wrote:

I want it to be controlled automatically to recognize that how many accelerometers has been uploaded and create as many plots area as a amount of accelerometers. 


If the max number is small (1..5, maybe), you could use an array of graphs (but they need to be inside a cluster). Here's one possibility. Still, it seem silly to resize the array, because you need to leave sufficient room for the max size.

 

altenbach_0-1646383462361.png

 

0 Kudos
Message 9 of 15
(2,214 Views)

That is not what wanted. There were no problem for me to create 4 graphs. but when you have more than 4 sensors that doesn't make sense to do it manually. That's why i need it to be done programmatically. (In this case machine was having not only accelerometers but also 6 strain gauges of them with 3 axis each. That's already 10 graphs that i need to add manually. But if next time i would like to measure another amount of graphs that wouldn't work and i need to reattach all of the wires again add new or delete old graphs)

0 Kudos
Message 10 of 15
(2,212 Views)