Esempio n. 1
0
    def contourf3D(self, X, Y, Z, *args, **kwargs):
        had_data = self.has_data()

        levels, colls = self.contourf(X, Y, Z, 20)
        print len(levels),len(colls)
        for z1,z2,linec in zip(levels,levels[1:],colls):
            zs = [z1] * (len(linec._verts[0])/2)
            zs += [z2] * (len(linec._verts[0])/2)
            art3d.wrap_patch(linec, zs, fn=draw_polyc)
        self.auto_scale_xyz(X,Y,Z, had_data)
        return levels,colls
Esempio n. 2
0
    def contourf3D(self, X, Y, Z, *args, **kwargs):
        raise NotImplementedError("contourf3D is broken")
        had_data = self.has_data()

        cset = self.contourf(X, Y, Z, *args, **kwargs)
        levels = cset.levels
        colls = cset.collections
        for z1,z2,linec in zip(levels,levels[1:],colls):
            zs = [z1] * (len(linec._verts[0])/2)
            zs += [z2] * (len(linec._verts[0])/2)
            # The following is clearly wrong.
            art3d.wrap_patch(linec, zs, fn=art3d.draw_polyc)
        self.auto_scale_xyz(X,Y,Z, had_data)
        return cset
Esempio n. 3
0
 def scatter3D(self, xs, ys, zs, *args, **kwargs):
     had_data = self.has_data()
     patches = Axes.scatter(self,xs,ys,*args,**kwargs)
     patches = art3d.wrap_patch(patches, zs)
     #
     self.auto_scale_xyz(xs,ys,zs, had_data)
     return patches
Esempio n. 4
0
 def scatter(self, xs,ys,zs=None,dir='z',*args,**kwargs):
     patches = self.wrapped.scatter(xs,ys,*args,**kwargs)
     if zs is None:
         zs = [0]*len(xs)
     patches = art3d.wrap_patch(patches, zs=zs, dir=dir)
     return patches