LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

line using cursor in xy graph

Solved!
Go to solution

hi

how i can draw line using cursor in xy graph

 

0 Kudos
Message 1 of 5
(3,862 Views)

Hi bijal,

 

Not sure what you are planning to do. But you could start with:

  1. Creating a XY graph. 
  2. Right click on the XY graph >> Visible Items>> Cursor Legend. 
  3. Right click on the cursor legend >> Create Cursor >> Free. Up to this step, you should able to create the cursor.
  4. To obtain the data from the cursor, go to your block diagram >> right click on the XY graph terminal at the block diagram >> Create >>  Property Node >> Active Cursor. This should create the property node for your XY graph. To change a selected property to write, right click on the active cursor >> Change to Read and it should be like below:
    1.JPG
    Just input 0 to access the first cursor
  5. Expend it to access an additional properties >> on the second property, click on it >> Cursor >> Cursor Position >> Cursor X. 
  6. Expend the properties until you see as below:
    2.JPG
    It Cursor.PosX and Cursor.PosY isn't changed to write, do change it to write by right clicking on Cursor.PosX >> Change to Write. Do the same for Cursor.PosY
  7. Up to point 6, you should be able to obtain data from the XY graph cursor.  
  8. Use those values to plot into the XY graph. I believe you'll need to find a way to plot XY graph by building an array of clusters. 

 

Hope it helps

 

Warmest regards,

Lennard.C

Learning new things everyday...
0 Kudos
Message 2 of 5
(3,852 Views)
Solution
Accepted by topic author bijal

Hi bijal,

 

you might change the appearance of the cursor to show as horizontal or vertical line, so you don't need to draw the line on your own…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 3 of 5
(3,838 Views)

Hi

Thanks for your suggestion.

But I want to draw the tangent line in graph to find intersection point .

 

Thanks

0 Kudos
Message 4 of 5
(3,803 Views)

Hi bijal,

 

use an additional plot in the graph to draw the tangent line!

Use two cursors (maybe set to small crosses) to define two points of the tangent line…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 5 of 5
(3,792 Views)