How to Plot XY Data from a 2D Array in LabVIEW

Updated May 21, 2018

Reported In

Software

  • LabVIEW

Issue Details

I have some x-y data in a 2D array that I'd like to plot in LabVIEW.

Whenever I connect an array wire directly to a XY Graph, I get an error telling me that I've connected two terminals of different types.

What do I need to do to plot my data?

Solution

The example below will allow you to use an XY Graph to plot a 2D array in LabVIEW.



The example starts with a two dimensional (2D) array, uses the 'Index Array' block to separate the array into two one dimensional arrays, one containing x and one containing y data and then bundles them into a cluster which is the expected input type of the XY Graph function.

Attachments

WAS THIS ARTICLE HELPFUL?

Not Helpful