05-30-2019 09:11 AM
Hello,
I want to plot a multi measurement in the same plot XY graph, but when I click to remeasure its plot the new measurement in the same plot. So, its connect the last value of the previous measurement with the first value of the next measurement i.e its doesn't create a new array but its just append the new values to the previous array. how can i create a new array on each call or just delete the line between this two values.
Thanks
Solved! Go to Solution.
05-30-2019 09:57 AM
What format is your data in? If you are using an array of XY pairs, they need to be combined for the graph using Build Cluster Array.
05-30-2019 10:29 AM
Actually I tried this build array cluster.
I attached my VI.
05-30-2019 10:54 AM
05-30-2019 11:05 AM
@BENTATA wrote:
Actually I tried this build array cluster.
I attached my VI.
Remember that when you just send your VI, we don't get your entire hierarchy (type defs, sub VI's, ect)
Here's a link that talks about using projects to better transfer your work.
A few notes:
1) These solutions are used in place of the "Build XY graph," express VI's
2) You may want separate your states a little more a common cycle is:
Initialize Instruments -> Configure -> Read Data -> Display Data -> Read Data ... ->Save -> Disconnect Instruments -> Exit
05-31-2019 03:47 AM
But in my states I need to recycle without deleting the previous data and to plot my new data in the same graph.
@JScherer wrote:
@BENTATA wrote:
Actually I tried this build array cluster.
I attached my VI.
Remember that when you just send your VI, we don't get your entire hierarchy (type defs, sub VI's, ect)
Here's a link that talks about using projects to better transfer your work.
A few notes:
1) These solutions are used in place of the "Build XY graph," express VI's
2) You may want separate your states a little more a common cycle is:
Initialize Instruments -> Configure -> Read Data -> Display Data -> Read Data ... ->Save -> Disconnect Instruments -> Exit
@JScherer wrote:
@BENTATA wrote:
Actually I tried this build array cluster.
I attached my VI.
Remember that when you just send your VI, we don't get your entire hierarchy (type defs, sub VI's, ect)
Here's a link that talks about using projects to better transfer your work.
A few notes:
1) These solutions are used in place of the "Build XY graph," express VI's
2) You may want separate your states a little more a common cycle is:
Initialize Instruments -> Configure -> Read Data -> Display Data -> Read Data ... ->Save -> Disconnect Instruments -> Exit
05-31-2019 04:19 AM
@BENTATA wrote:
But in my states I need to recycle without deleting the previous data and to plot my new data in the same graph.
You can do this using property nodes. Here's an example.
You can use the reference to the XY graph control to do this in a subVI if it suits your code structure (I couldn't look at your VI as I only have LV2015).
Andy
05-31-2019 06:35 AM
@PsyenceFact wrote:
@BENTATA wrote:
But in my states I need to recycle without deleting the previous data and to plot my new data in the same graph.
You can do this using property nodes. Here's an example.
You can use the reference to the XY graph control to do this in a subVI if it suits your code structure (I couldn't look at your VI as I only have LV2015).
Andy
Thanks very much for your help, Could you please tell me how to make my data output as yours (from a 2D array to a cluster of two elemets). I tried convert array to cluster but it doesnt work.
05-31-2019 07:24 AM
@BENTATA wrote:Thanks very much for your help, Could you please tell me how to make my data output as yours (from a 2D array to a cluster of two elemets). I tried convert array to cluster but it doesnt work.
Array To Cluster only operates on a 1D array. You need to use Index Array to get the two rows of your 2D array (presumably containing X and Y data) then Bundle to create the cluster. This can then be turned in to an array.
05-31-2019 09:40 AM
Thank you for your help, I tried to connect the read value + the new data in the write value as you did but it didnt work.