LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to plot X,Y,Z data on a 3D Graph

I would like to plot a X,Y, and Z data on a 3D Graph. The moving point as (X1, Y1, Z1), while the stationary point as (Xo,Yo,Zo). I would like to plot this two points in the 3D Graph connected together with a line. Kindly teach me how can I improve the attached VI. Thank you very much.
0 Kudos
Message 1 of 13
(4,490 Views)
Hi Bong
 
You are not that far from the solution. You just have to build the arrays (X,Y and Z) with the values from both points. So the arrays would look like this:
X = (x0, x1), Y = (y0, y1) and Z = (z0, z1).
Just have a look at the attachment.
 
Hope this helps.
 
Thomas
Using LV8.0
--------------------------------------------------------------------
Don't be afraid to rate a good answer... 😉
--------------------------------------------------------------------
Message 2 of 13
(4,481 Views)
Hello Mr Thomas,
 
Thank you very much for the reply. It does help me a lot.
 
Please find the attached. This is what I am trying to do. The Base Point, Senkai Point, Fix Point and Moving Point are showing correctly, but the First and Second Limit Point should stay in the floor level (not attaching the moving point). Kindly teach me the correct way to do it.
 
Again, thanks a lot.
0 Kudos
Message 3 of 13
(4,476 Views)
Hi
 
What do you mean with "should stay in the floor level (not attaching the moving point)"?
Using LV8.0
--------------------------------------------------------------------
Don't be afraid to rate a good answer... 😉
--------------------------------------------------------------------
0 Kudos
Message 4 of 13
(4,468 Views)

Hello Mr Thomas,

I am sorry for the confusion. What I mean is the First and Second Limit Points since their height is "Zero" should lie on the zero plane. But what happens is it connects to the end of the moving point. How can I remove that connection and let the line First and Second Point lie on the plane independently.

Thanks a lot.

0 Kudos
Message 5 of 13
(4,452 Views)

To disconnect those points from the rest of the plot, exclude them from the plot!

To do this, you will have to use more than one plot. In reply #7 an onward of this thread

http://forums.ni.com/ni/board/message?board.id=170&message.id=143663&jump=true

I show lot of 3d graph techniques including multiple plots. Reply #8 is where I show how to add plots.

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 6 of 13
(4,447 Views)

Dear Ben,

 

Thank for the reply and the VI. I am studying the VI you have attached and actually re-doing it again so i will learn how to make it. But kindly teach me the name of the function connected to the "Line Color" inside the For Loop. I have been searching that figure but I am not sure if i  have it.

Appreciate your reply.

Regards,

0 Kudos
Message 7 of 13
(4,426 Views)

Hi Ben again,

I am sorry for asking too much. Based on your VI, are the "Set Color Trans", "Set Axis Range" and "Add Cursor" sub VI's? Also the DATA IN is a string data, is it in the form of clusters of strings? I am sorry but I am really new in this 3D functions. Is there a more simple VI similar to my example above that I can follow to realize my question?

Thank you for your patience.

0 Kudos
Message 8 of 13
(4,421 Views)

Hi Bong,

Reply #7 of of that thread I pointed to in my previous reply includes the original source code.

Down load the zip and have fun!

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 9 of 13
(4,412 Views)
Hi everybody,
 I would like to know if it is possible to do that : (write a point (with X,Y,Z coordinates) every 100ms and that will make my 3D curve)
Because I 'm collecting data from a 3 axes accelerometer with a sample rate of like 1 point every 100ms ,I would like to be able to write one point 3d point on the 3D curve every 100ms and draw a line beetween the two points
do you know how can I do that
thanks
olivier
I attach my VI and the data text file
Download All
0 Kudos
Message 10 of 13
(4,256 Views)