12-01-2014 12:27 PM
Hey guys,
I am new to labview and I'm wondering if it's possible to plot only one point in a XY Graph, and if it is, how can I do this? I see that when I select XY Graph in block diagram, it only has one place to wire, it doesn't have a place where I can put my X and Y coord's to that specific point... I'm lost here!
Thanks for any help, guys!
12-01-2014 01:24 PM
Here is a good way ot get "unlost" in such situations: Always keep the Context Help window open while programming.
On the block diagram move the cursor over the XY Graph terminal. The context window will show how to connect data to the graph. Ther is also a detailed link to the help files for more information.
To answer your specific question you need a bundle node. You wire the X array to the first terminal and the Y array to the second. Since you have only one point, you will need to convert the scalars representing the coordinates to single element arrays.
OR
You can create an array of points (containing only one point) where a point consists of a cluster of two numeric scalars representing the X and Y coordinates.
OR
You can create an array of complex (again, containing only one point) with the complex data having the form x + i*y.
All of that information is in the help.
Lynn
12-01-2014 01:49 PM
Hey johnsold,
Thanks for your answer! I tried to create a bundle node (I think), as you said, but I can't connect the end of the bundle to the XY Graph. I tried to put some things to convert, I tried cluster to array and a little fre more, but still can not do this... Could you look at what I'm doing and see if I'm doing it right? If yes, how can I convert the signal properly?
Thanks for your help!
12-01-2014 02:03 PM
Did you read the context help like he suggested? It's pretty useful. Especially the Detailed Help.
12-01-2014 02:10 PM
- Ctrl - H
- Hover cursor over XY Graph
- Context Help should have a link called "Detailed Help" at the bottom
- Click "Detailed Help"
- Look for "Displaying a Single Plot on XY Graphs" in the LabVIEW help that should pop up
- Click "Open Examples"
- Push Kudo next to DailyDose
12-01-2014 02:10 PM - edited 12-01-2014 02:17 PM
@Pedro_ wrote:
Thanks for your help!
Just insert a "built array" of height=1 between the bundle and the graph terminal.