LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Plot new axes on intensity graph

Solved!
Go to solution

I am trying to draw XY axes through an arbirtary point on an intensity graph. I can draw two lines across the image (following posts like that linked below), but they don't seem to actually endf up a the coordinates I spesify. I know that I need to correct for the fact that the vertical scale increases from top to bottom, but how can I draw lines at the (x0,y0) position I spesify? It seems that the lines are overlaid on the image, but not linked to the actual axes of the intensity graph.

 

 

http://forums.ni.com/t5/LabVIEW/overlaying-XY-line-onto-intensity-graph/td-p/398963

 

 

0 Kudos
Message 1 of 12
(4,651 Views)

you can use PlotAreaSize:

xy.png

0 Kudos
Message 2 of 12
(4,606 Views)

Thanks. I'm still confused. I see that bounds was wrong because it found the size of the object, not nessesarily the plotting region. But PlotAreaSize seems to do the same thing. I want to draw a line at say (100,150) on the intensity graph, independent of the size of the chart.

 

Also, the options I get under the property node PlotAreaSize in my Labview appear to be different than in the picture you provided.

0 Kudos
Message 3 of 12
(4,602 Views)

@teroenzaa wrote:

Thanks. I'm still confused. I see that bounds was wrong because it found the size of the object, not nessesarily the plotting region. But PlotAreaSize seems to do the same thing. I want to draw a line at say (100,150) on the intensity graph, independent of the size of the chart.



no PlotAreaSize - size of plot area only, Check it.

You need size of pixel in axis unit. So, you take plot size (pixels) and divide it to axis size.

 

Also, the options I get under the property node PlotAreaSize in my Labview appear to be different than in the picture you provided.

You  can select any property in any order. You need axis size.
Btw, if your axis start not from 0, take range maximum and minimum.
Max-min=axis size

0 Kudos
Message 4 of 12
(4,598 Views)

Thanks so much. i think I understandnow.

 

Now I'll try rotating the lines by a user-spesified angle. 🙂

 

0 Kudos
Message 5 of 12
(4,595 Views)

Degrees to radians and sine+cosine.
Or XY to polar -> change angle -> polar to XY

0 Kudos
Message 6 of 12
(4,591 Views)

Thanks. I ended up feeding the points into the 2D Cartesian Coordinate Rotation VI, but it's not right. I think this is because it is rotating about the origen and not the cursor point. I tried translating back to the origen, rotating, then translating back, and it seems to have a similar problem (forgive the dumb way I did that).

Download All
0 Kudos
Message 7 of 12
(4,578 Views)
Solution
Accepted by topic author teroenzaa

rotate.png

 

but you need made "vertical mirror"

0 Kudos
Message 8 of 12
(4,556 Views)

I don't understand where  the "vertical mirror" comes in. I see that you convert to polar coordinates then add the angle (much more clever than my solution).

0 Kudos
Message 9 of 12
(4,548 Views)

In my vi point(0,0) at left upper corner. You need left down.

0 Kudos
Message 10 of 12
(4,515 Views)