From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Setting different precisions for Y-scale and cursor position

How can I set the precision for the cursor position to 4 such that the Yscale precision remains zero?

Apparently when you change the precision either from the scale legend or the graph properties, it affects both the precision of the Yscale and the cursor position at the same time.

[BADGE NAME]

0 Kudos
Message 1 of 30
(4,952 Views)

Can you attach a simple VI demonstrating the problem?

 

0 Kudos
Message 2 of 30
(4,939 Views)

Welcome back worthy Kinght 🙂 I thought my explanation should be clear enough. However, attached is a vi explaining the problem. The yscale precision "follows" the cursor postion precision but i want to have a precsion of zero on the yscale on the graph but a precision of 4 for the cursor y positions on the cursor legend.

[BADGE NAME]

0 Kudos
Message 3 of 30
(4,930 Views)

The Cursor Position "box" is simply a "view".  Where the cursor "really" is will be governed by how many pixels are in your graph, as the cursor moves in units of pixels.

 

The Precision in Display Format, similarly, is for the viewer's convenience.  If you choose to show the numbers from 1 to 100 with 4 digits of precision (1.0000 to 100.0000), LabVIEW doesn't say "That's just silly", but does what you ask.  Since the "view" of the Cursor is necessarily linked to the X and Y scales, NI chose the (logical, in my view) option of setting the Cursor View precision to match that of the corresponding axis.  It is a Feature (and, I believe, a good one), not a bug.

 

Note that if you read the cursor position in your code, you are free to display the value however you wish.

 

Bob Schor

0 Kudos
Message 4 of 30
(4,889 Views)
Bob what I found is that initially when place a graph on the front panel, wire data to the terminal and run the vi Labview does the right thing ( in my opinion ) of displaying the Yscale with zero digit precision and the cursor position with the actual number of digits of precision inherent in the data you wire to the graph. At this time too you will find that all the format options in scale legend ( decimal, SI etc) are unchecked) The moment you play around with the scale legend and check any of those format options you get into theis scenario of not being able to set Yscale back to zero and having your cursor positions display with the right number of precision digits.

[BADGE NAME]

0 Kudos
Message 5 of 30
(4,886 Views)
In this example I didn't use cursor position data with four digits of precision but I have seen the above happen. My actual cursor position data ( not synthesized with random number) is actually four digits precise and i need to display that in the cursor legend as such while keeping the Yscale digit of precision at zero. This happens correctly when you place a fresh graph but like I said once you make any changes in the scale legend you get into this scenario where you can't have back the initially corect status

[BADGE NAME]

0 Kudos
Message 6 of 30
(4,884 Views)

Some comments.

  • If it is initially "right", but if you fiddle with it, you can't return to the default "unspecified" setting, don't fiddle.  
  • The LabVIEW designers were probably trying to use "intelligent defaults", and when you start to mess with the graph, you "tell" LabVIEW specific settings.  
  • I'm not sure you are correct about the setting being "stuck".  I dropped another Mixed Graph, and found that the Display Scale defaults were X having 0 digits of precision and Y having 6 significant digits, with Floating Point as the default type.  I had not problem setting your plot to this.
  • As I noted earlier, if you don't like something about how LabVIEW chooses to display the Cursor values, use properties to get the values yourself and display them in your own Indicator (instead of using LabVIEW's view).
0 Kudos
Message 7 of 30
(4,881 Views)
Bob I am referring mainly to the Yscale and the cursor Y position, not the X cursor position versus the Y cursor position

[BADGE NAME]

0 Kudos
Message 8 of 30
(4,878 Views)
By Y cursor position I mean Y co-ordinate points on the plots corresponding to certain times on the X -axis. By Y scale I mean the "scale" of the Y axis not the actual Y co-ordinates on the plots. I want the scale of the Y axis to show up with zero digits of precision, while the T cursor position ( Y co-ordinate points) show up with four or as many number of digits inherent in the data points plotted.

[BADGE NAME]

0 Kudos
Message 9 of 30
(4,877 Views)
Also move the multi-plot cursor after making any changes to confirm if your Y cursor precision digits actually differ from the Y scale precision digits.

[BADGE NAME]

0 Kudos
Message 10 of 30
(4,876 Views)