Ask Your Question
1

Plot a list of 3D data

asked 2011-05-17 18:01:22 +0100

v_2e gravatar image

updated 2011-05-22 14:58:34 +0100

Kelvin Li gravatar image

Hello! I have a task to plot a list of 3D data of the following form:

 x  y  z
(1, 1, 1)
(1, 5, 7)
(8.8, 0, 3)
(7.5, 1.91, 11.8)
(0, 0, 0)

It looks like with "list_plot3d()" I can only get a surface, while I need just the dots with the appropriate coordinates (x, y, z). How can I do that?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
3

answered 2011-05-17 18:16:48 +0100

benjaminfjones gravatar image

Try the point3d function:

sage: L = [ (1, 1, 1), (1, 5, 7), (8.8, 0, 3),  (7.5, 1.91, 11.8), (0, 0, 0) ]
sage: point3d(L)

See the documentation for point3d by typing point3d? at the command line. See the text3d function if you want to add text labels to your points.

edit flag offensive delete link more

Comments

Thanks a lot! This is indeed what I wanted to do! To my mind, this function is definitely belongs to the "3D Graphics" section of the Tutorial. Maybe even to "List Plots" subsection, because such function is used very often.

v_2e gravatar imagev_2e ( 2011-05-17 18:39:10 +0100 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2011-05-17 18:01:22 +0100

Seen: 1,708 times

Last updated: May 17 '11