LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Build Array - 4 elements which have 3 empty array and 1 array with value and build into cluster of 3 element to display in graph chart, the graph chart still display the empty array with the value 0

the empty array still appear in the graph chart, with the value 0, how to make it not to appear in the graph chart?

i have variables to determine which array is empty or have value in it
0 Kudos
Message 1 of 4
(2,696 Views)
When you use the build array with one array that's empty and one array that's not, you cannot get a 2D array with one row or column that's empty - it's simply not a valid array. So that's where your 0 values come from. You could fill the empty arrays with NaN or set the plot color for those arrays to be transparent.
Message 2 of 4
(2,696 Views)
Hi Dennis,

Didn't know that the build array have such behaviour, if i initialize array and the demension size is 120000
and i build 3 such arrays in the same time, will it slow down the program?
0 Kudos
Message 3 of 4
(2,696 Views)
Initializing arrays and using Replace Array Element is usually faster than building arrays in a loop because of memory allocation issues as the array grows.

You may not want to display on a graph more than a few hundred points at a time. The user cannot interpret more than that and updating the screen can be very time consuming with large numbers of points. Display speed is a complex function of OS, graphic hardware and software, much of it outside the control of LV. Also, updating a graph more than a few times per second is a waste of resources.

Lynn
0 Kudos
Message 4 of 4
(2,696 Views)