11-09-2016 10:45 PM
Hi fnds,
I am facing a problem in clearing the previous value of XY graph before starting a new execution. I went through NI forums & blogs & fed my X & Y value to express XY graph along with reseting its value from one of its input. But still the same output remains, not able to clear previous value. any suggestion please.
11-10-2016 12:50 AM
reshmi.0989@gmail.com wrote:Hi fnds,
I am facing a problem in clearing the previous value of XY graph before starting a new execution. I went through NI forums & blogs & fed my X & Y value to express XY graph along with reseting its value from one of its input. But still the same output remains, not able to clear previous value. any suggestion please.
It is not really clear what you try to do. You should show (attach!) your VI what you tried so far. Keep in mind, an XY Graph always shows what you connect to it. If you want to clear a Graph, you need to connect empty data arrays to it.
Maybe you want to use a Chart instead of a Graph? A chart has a history, it keeps previous data points, but of course you can also clear charts.
An XY Graph is often used alongside with a shift register: you can keep those data point value pairs in memory which you need to plot at iterations, and you can also manipulate these array as needed.
Anyway, show us what you have, and explain clear what you want.
11-10-2016 04:07 AM
11-10-2016 09:52 AM - edited 11-10-2016 09:56 AM
Here is what I like to do. Treat your graph like an Action Engine http://forums.ni.com/t5/LabVIEW/Community-Nugget-4-08-2007-Action-Engines/m-p/503801 and have an initialize case so you can clear the graph when necessary.
This is a sub-vi to a larger program that is monitoring a grid tie inverter, this one graphs "solar harvest"
At midnight I do an "initilize" to clear the graph and setup the X-axis for the next day.
11-10-2016 11:48 AM
If you use the "build xy graph" express VI, make sure it is not set to retain data between calls. In that case, the data accumulates inside the express VI.