02-23-2023 04:36 AM
Hi everyone, i have the following problem:
My code has a case structure wired to an enum, in each case i perform a series of operations that lead to the building of an x/y chart that can be multiplot or single plot based on the case im executing. My problem is that i wanted all the cases to be displayed on the same x/y graph indicator but, when i try to wire a single plot to my indicator my wire is broken.
Is there a way to change my x/y graph programmatically so that it can display the type of graph im building independently? or any other way to solve this?
Solved! Go to Solution.
02-23-2023 04:56 AM - edited 02-23-2023 04:57 AM
Hi dom,
@domcorrado wrote:
My problem is that i wanted all the cases to be displayed on the same x/y graph indicator
What's the difference between an array containing a single plot and an array of more than one plot?
Answer: for the XYGraph there is no difference, it will accept both on the same wire!
So the question is: why does your "single plot" case doesn't output an array of exactly one plot?
02-23-2023 12:24 PM - edited 02-23-2023 12:24 PM
@domcorrado wrote:My code has a case structure wired to an enum, in each case i perform a series of operations that lead to the building of an x/y chart that can be multiplot or single plot based on the case im executing. My problem is that i wanted all the cases to be displayed on the same x/y graph indicator but, when i try to wire a single plot to my indicator my wire is broken.
Is there a way to change my x/y graph programmatically so that it can display the type of graph im building independently? or any other way to solve this?
A long litany of vague descriptions does not help. Please attach your code.
In the title, you talk about xy graph, but in the description, you talk about xy chart, something that does not even exist.
XY graphs accept a huge number of datatypes (arrays of points, arrays of clusters of arrays of points, complex 1D array, array of clusters of complex 1D arrays, clusters of x and y arrays, arrays of clusters of x and y arrays, etc. etc.) and the exact solution critically depends on what you have. Once you attach your VI, we can probably fix it instantly.