LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

display the data values at cursor position

i would like to see the value of data point on graph when the cursor is placed on data point ,specifically if the point is clicked i can display data for requested point in a numeric control off the chart.
0 Kudos
Message 1 of 4
(6,876 Views)
Attached is a vi which displays power spectrum with cursors at its two peaks (with peak values displayed)

Note:
As this is only part of my Dynamic VI, I have it modified with simulated data.

In order to see the cursor position/ value change, simply adjust the detected amplitude/ frequency, follow by adjusting the Power Spectrum's magnitude.

Hope this will help.
ian
Ian F
Since LabVIEW 5.1... 7.1.1... 2009, 2010, 2014
依恩与LabVIEW
LVVILIB.blogspot.com
0 Kudos
Message 2 of 4
(6,876 Views)
The easiest solution is just to show the cursor legens of the graph and set the cursor to snap to point or lock to plot...the cursor legen will then display both the x and y value of the plot at the cursor position...

However sometimes it's necessary to extract that info for other purposes or the cursor legens is just too big, ugly or gives too many options to be displayed...then you need to use the cursor properties of the graph:

Use Active cursor to set or read out what is the active cursor...then read out the position of the cursor using the Cursor.Position property, or alternatively read out the x position using the cursor index and then find the y (and x if that is not an index but a time e.g.) by looking up that index in the array displayed on the graph..
.

If you have several cursors make a loop where you set the active cursor, read out its position, then set the active cursor to the next cursor...etc.

Mads
Message 3 of 4
(6,876 Views)
0 Kudos
Message 4 of 4
(6,876 Views)