LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 
Reply

Need versatile way to pass data to graph

Solved!
Go to solution
Highlighted

Hi,

I have a sub-vi that does some data analysis. I output the results through a type def. I want this type def to include the data needed to plot the results in a XY-graph.

 

My problem is that the data will sometimes contain only 1 data series and sometimes multiple ones. i.e. sometimes the output should be a cluster of two 1D-arrays, sometimes it should be an array of clusters. Is there a good way to achieve this?

 

Skärmklipp.JPG

vs

Skärmklipp2.JPG 

0 Kudos
Message 1 of 4
(1,103 Views)

Dulpicate Post,

please maintanin single thread

http://forums.ni.com/t5/Getting-Started-on-the-NI/Tips-for-Posting-Code/td-p/3250924

Palanivel Thiruvenkadam,
Certified (LabVIEW || TestStand) Developer
0 Kudos
Message 2 of 4
(1,098 Views)

You can try using for loop with indexing enabled so that you will come to know how many coulumns you have during run time and cluster them and then index out so that you will have array of clusters always.

Thanks
uday
Message 3 of 4
(1,090 Views)
Solution
Accepted by topic author HenrikOlsson
08-17-2016 05:40 AM

@udka wrote:

You can try using for loop with indexing enabled so that you will come to know how many coulumns you have during run time and cluster them and then index out so that you will have array of clusters always.


You are on the right track.  Just need a little bit before the loop to transpose the array (to make the indexing work properly) and remove the X-axis data.


There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
Message 4 of 4
(1,077 Views)