[Matplotlib-users] plotting a series of 3D points and, picker=True and 3D

Yes, it is probably a good-sized chunk of work. In the recent transforms overhaul, the 3d stuff was deferred, so it hasn't been updated to use the new "way of doing things".

Just "getting it to work as it did before" is probably less work than "rethinking what 3D means in the context of matplotlib", which is a fundamentally 2D plotting environment. And there was some thinking along the lines of "why bother with the former, if the latter may be on the horizon?..." But I think it's going to take some motivated individual to step up and do either of these.

Cheers,
Mike

Johann Cohen-Tanugi wrote:

···

is there a lot of work involved in getting it in? I can wait a bit, or even try to help out.... It is not critical as I know plenty other way to get the plot I want.... Just that I love matplotlib and scipy

best,
Johann

Michael Droettboom wrote:

The axes3d stuff is not currently working on the SVN trunk. You probably want to use 0.91.2 or the v0_91_maint branch in SVN instead.

Cheers,
Mike

Johann Cohen-Tanugi wrote:

hello,
thanks for answering. I actually fail with the import :
In [1]: from matplotlib import axes3d
---------------------------------------------------------------------------

ImportError Traceback (most recent call last)

/home/cohen/bstw/<ipython console> in <module>()

/usr/lib/python2.5/site-packages/matplotlib/axes3d.py in <module>()
     14 from axes import Axes
     15 import cbook
---> 16 from transforms import unit_bbox
     17
     18 import numpy as npy

ImportError: cannot import name unit_bbox

any idea?

----------------------------------------------------------------------

Message: 1
Date: Sun, 27 Jan 2008 22:18:00 +0000
From: "Neil Crighton" <neilcrighton@...149...>
Subject: Re: [Matplotlib-users] plotting a series of 3D points and
    picker=True and 3D
To: matplotlib-users@lists.sourceforge.net
Message-ID:
    <63751c30801271418m66f88113md6e7a0f42bef29f4@...150...>
Content-Type: text/plain; charset=ISO-8859-1

I think scatter3D does what you want:

from matplotlib import axes3d
import pylab as pl
fig = pl.figure()
ax = axes3d.Axes3D(fig)
ax.scatter3D(data[:,0],data[:,1],data[:,2])
ax.set_xlabel('X value')
ax.set_ylabel('Y value')
ax.set_zlabel('Z value')
pl.show()

You could also change the colour and size of each point based on other
array values:

col = ax.scatter3D(data[:,0], data[:,1], data[:,2], c=data[:,3],
cmap=pl.cm.jet, s=data[:,4])
cbar = fig.colorbar(col,shrink=0.9,extend='both')
cbar.ax.set_ylabel('axis 3 data values')

Pretty nifty.

Neil

-------------------------------------------------------------------------

This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

--
Michael Droettboom
Science Software Branch
Operations and Engineering Division
Space Telescope Science Institute
Operated by AURA for NASA