First time here? Check out the FAQ!

Ask Your Question
1

Plot a list of 3D data

asked 13 years ago

v_2e gravatar image

updated 13 years ago

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?

Preview: (hide)

1 Answer

Sort by » oldest newest most voted
3

answered 13 years ago

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.

Preview: (hide)
link

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 ( 13 years ago )

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: 13 years ago

Seen: 1,766 times

Last updated: May 17 '11