03-07-2015 01:38 PM
Please note that you don't actually need a chart. What you need is something that looks like a chart. Mike...
Did you want to expand on that or do you normally speak in riddles?
03-07-2015 02:38 PM
03-07-2015 03:18 PM
What I'm trying to say is.... the amount of data I have to graph every second.... grows every second. So eventually the amount of time it would take to plot all those data points on a graph would take longer than the time i have....which is 1 second....which is why I am using a chart, as stated in the begining.
If you have a solution that uses a graph and allows me to add 1 point of data to it every second while still displaying all previous data (like a chart), instead of redrawing all the data every second, I would be excited to look at it.
I would imagine you could remove data from the array to be graphed, reducing the amount of data that needs to be drawn.... but arbitrarily dropping data points isn't an option for my current application.
As I haven't been able to find a way to "make a graph act like a chart", and you are not offering a concrete example for me to look at, the original question stands.
How does one draw text or an image of text onto a chart? Currently I am working with Vltan's idea of using an image and placing it over the chart, to see how that works out.
03-07-2015 03:24 PM
You drop the oldest data out of your array before sending to the graph, which is the same thing the waveform chart does.
03-07-2015 03:35 PM
I cant drop data.....
I have to display all data, i'm using the charts history variable, which makes the chart display all historical data...without scrolling the chart.
In the inital post.....
Yes, I know a graph would be better for this, but I have to use a chart for my application.
03-07-2015 03:44 PM
True, but all that it is doing is maintaining that history array internally and then plotting a subset of it for the visible portion.
You could do this yourself with a graph by maintaining the history array in your VI and providing a different subset to the graph indicator each time you want it to update.
03-07-2015 03:48 PM
Would i not have to draw each data point of that subset to the graph to display it?
03-07-2015 03:58 PM
I'm not exactly sure what you mean.
You provide the graph an array of points that you want it to display. That array would contain each point of the subset that you want to display.
So you have your internal array where you are storing the history, which you are adding one point to each time, and you have your graph, to which you are providing a subset of the history array to each time.
03-07-2015 04:10 PM - edited 03-07-2015 04:12 PM
lets say I have 1 million points of data to show on a chart or graph and I want to add 1 more point....
A graph would require me to send to it an array with 1,000,001 data points which it would then draw, point by point, onto the graph.
A chart would require me to send 1 data point to it which it would then append onto the existing points.
My problem currently, isnt the amount of data I have to draw.... its the time in which it takes a chart VS a graph to actually draw the new data.
Since I only have X amount of time to draw a new chart/graph with new data....the chart, in this case, is quickest.
Edit:
Maybe I'm just not understanding what your saying?
03-07-2015 04:25 PM
First of all, a chart does not have an infinite history, which it is starting to sound like how you think you will use it.
Secondly, you want to plot the entire set of data every second, not just some recent subset such as the last 100 seconds?
Third, how do you think that the chart is redrawing the data? Usually if something seems impossible / free, it is (impossible). I believe that the chart still has to redraw its entire plot area point-by-point when you add a new point, same as the graph. The action on your part (adding one new point vs. giving it a brand new array) is the only difference.
However, I don't know if the Waveform Chart in LabVIEW is internally more efficient in how it updates and redraws, so maybe it is faster for some cases - did you confirm this?