04-16-2010 08:44 AM
Hello,
I've a problem with some XY-Graphs. I want to fit the y-scale to data when pushing a button. My problem is, when using a property node setting YScale.ScaleFit to 1 the y-scale is fitted to the whole data stored in the XY-Graph and not only to the visible data. I would like LabVIEW only to consider data points within the range of the x-scale. Do you know any solution, except calculating the maximum and minimum of the data-points within the range of the x-scale and then adjusting the scales?
Regards,
eme
04-16-2010 09:03 AM
04-16-2010 09:16 AM
OK this would be another way to do that. Am I guessing right that LabVIEW has no built in function that could solve my scaling problem?
Regards,
eme
04-16-2010 10:42 AM
Not to my knowledge. If you bent on using the auto-scale feature, and your data set is not abnormally large, you could put it in a sub-VI, and auto-scale X and Y. Then read the values of Y out. But if you are building an application, you may need to insure to include the FP diagram of the sub.
My solution would be to take the max/min of the input data set. Round that to a suitable range for your application and write that to the Y min and max values. Voila, your own autoscale routine.
03-18-2011 11:09 AM
Just to give this a poke...
So it is not possible to autoscale to only the visible data on an XY Graph? -the default is to autoscale to the whole data set, regardless of how much of it is actually displayed?
If the default is the only case, it seems a little inconsistent given:
1, there is a function to display only part of the dataset (X/YScale.range property node),
2, the autoscale function does autoscale if different plots are made visible/invisible.
Achieving autoscaling by editing the data set so that only data that you wish is displayed is in the data set sent to the graph (as suggested earlier in this thread) makes the functions 1 & 2 above redundant.... ?
This also appears to be different to Waveform Chart behaviour, which does autoscale to what is visible. This is despite the Waveform Chart retaining data which is not necessarily displayed (eg. if 'Chart History Length' is larger than X axis max - X axis min).
...or have i just missed a property node somewhere?
Blue
09-12-2013 02:27 PM - edited 09-12-2013 02:27 PM
Hm, I just stumbled upon the same issue (LabView 2012) and it is indeed a very annoying one.
It would've been great if there were an easier solution than writing one's own autoscaling routines...
09-24-2013 01:00 PM
+1, that's very irritating.
Hope NI will improve this autoscale to effective displayed data (or let the user choose which one scale method to use)
09-24-2013 01:13 PM
-2 (!)
On the other hand, if you write your own autoscaling routine (which can be really simple), then you know exactly what is happening and why. You really only have to write the basic routine once. It's then much easier to tweak for specific situations than an NI-built autoscale, because NI has to please everybody and you only have to please yourself (and your boss/customer).
Cameron
09-18-2017 10:32 AM
+3 -1 = +2 (!)
The Waveform chart exhibits the desired behavior already, so the XY graph simply has a bug. Writing our own autoscale routine is the wrong solution just to fix a bug.
@camerond wrote:
-2 (!)
On the other hand, if you write your own autoscaling routine (which can be really simple), then you know exactly what is happening and why. You really only have to write the basic routine once. It's then much easier to tweak for specific situations than an NI-built autoscale, because NI has to please everybody and you only have to please yourself (and your boss/customer).
Cameron