Example #1
0
    def plots_3d(self, ts, outpath, prefix=''):
        c_iso = 10 ; r_iso=10
        kinds = ['contourf', 'contour']
        views = ( (14, -21), (28, 17), (5, -13), (48, -14), (14,-155) )  #elev, aziumuth
        for kind in kinds:
            out3d = op.join(outpath, '3dplots_'+kind)
            logmkdir(out3d)

            for view in views:        
                spec_surface3d(ts, kind=kind, c_iso=c_iso, r_iso=r_iso, 
                    cmap=cmget('gray'), contour_cmap=cmget('autumn'),
                    elev=view[0], azim=view[1], xlabel='Time ('+ts.timeunit+')'
                              )
                self.plt_clrsave(op.join(out3d, prefix + 'elev:azi_%s:%s' %
                                         (view[0], view[1])))         
Example #2
0
def corr_3d(df, **pltkwds):
    ''' 3d plot suited for correlation analysis.  If special "speclabel" keyword is passed, it will
        add the "spectral label" to both the x and y-axis.  Otherwise, x,y,z labels can be set through 
        their own keywords.'''

    if 'speclabel' in pltkwds:
        pltkwds['xlabel']=pltkwds['speclabel']
        pltkwds['ylabel']=pltkwds['speclabel']
                
    pltkwds['elev']=pltkwds.pop('elev', 31)
    pltkwds['azim']=pltkwds.pop('azim', -52)    
    return spec_surface3d(df, **pltkwds)