ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

chart array elements separately

Labview forum,

I have a for loop which produces an array of 2 elements.
This is contained within an outer loop.  Inside the outer loop, I have connected the array to a chart function.  For each outer loop iteration, the the chart plots both array elements as sequential elements in the same plot.  This was not the behaviour I wanted.

Instead, with each outer loop increment, I would like each array element to be added to a separate curve on the same chart axes.  Thus, in this case, two curves would be plotted simultaneously.
How can I achieve this?

Attached is a simple example of my current situation.

Regards,
Jamie

Message Edited by Jamieg on 09-17-2007 06:45 AM

Using Labview version 8.0
Download All
0 Kudos
Message 1 of 6
(4,077 Views)
Jamie,

here a possible solution:


hope this helps,
Norbert B.

Message Edited by Norbert B on 09-17-2007 07:52 AM

Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 2 of 6
(4,060 Views)

Hi Jamie,

I hope that your problem might ve been solved by Norbert's suggestion.

But please dont post duplicate copies of attachments.

- Partha ( CLD until Oct 2027 🙂 )
0 Kudos
Message 3 of 6
(4,047 Views)

An alternative solution uses the "array to cluster" function. (Don't forget to set the cluster size!)

Message Edited by altenbach on 09-17-2007 07:50 AM

Download All
0 Kudos
Message 4 of 6
(4,041 Views)
Thanks for your help Norbert and Altenbach.
I knew it would be something simple.
It is strange, though, that with Norbert's suggestion we logically convert the 1-dimensional array into a "2-dimensional" array even though that "2-dimensional array" still only has one dimension of data.
Regards,
Jamie


Message Edited by Jamieg on 09-17-2007 08:38 PM

Using Labview version 8.0
0 Kudos
Message 5 of 6
(4,018 Views)


@Jamieg wrote:
even though that "2-dimensional array" still only has one dimension of data.

No, it has two dimensions, one of the dimensions is size 1, though 🙂

You can even have a 1D array of size 0 and a 2D array of size 0 x 0, for example. Not the same!

Message 6 of 6
(4,008 Views)