Changeset 516 for trunk/UTIL/PYTHON
- Timestamp:
- Feb 4, 2012, 1:16:59 PM (13 years ago)
- Location:
- trunk/UTIL/PYTHON
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/UTIL/PYTHON/myplot.py
r511 r516 623 623 #steplon = 5.625 624 624 #zelatmax = 89.9 625 m.drawmeridians(np.r_[-180.:180.:steplon], labels=[0,0,0,1], color=zecolor, linewidth=zelinewidth, fontsize=fontsizemer, latmax=zelatmax) 626 m.drawparallels(np.r_[-90.:90.:step], labels=[1,0,0,0], color=zecolor, linewidth=zelinewidth, fontsize=fontsizemer, latmax=zelatmax) 625 if char not in ["moll"]: 626 m.drawmeridians(np.r_[-180.:180.:steplon], labels=[0,0,0,1], color=zecolor, linewidth=zelinewidth, fontsize=fontsizemer, latmax=zelatmax) 627 m.drawparallels(np.r_[-90.:90.:step], labels=[1,0,0,0], color=zecolor, linewidth=zelinewidth, fontsize=fontsizemer, latmax=zelatmax) 627 628 if back: m.warpimage(marsmap(back),scale=0.75) 628 629 #if not back: … … 726 727 "DOWNDRAFT": "%.0f",\ 727 728 "TK": "%.0f",\ 729 #"ZMAX_TH": "%.0f",\ 730 #"WSTAR": "%.0f",\ 728 731 # Variables from TES ncdf format 729 732 "T_NADIR_DAY": "%.0f",\ -
trunk/UTIL/PYTHON/myscript.py
r507 r516 15 15 parser.add_option('-w', '--with', action='store',dest='var2', type="string", default=None, help='variable contoured') 16 16 parser.add_option('-a', '--anomaly',action='store_true',dest='anomaly', default=False, help='compute and plot relative anomaly in %') 17 parser.add_option('--mult', action='store',dest='mult', type="float", default=1., help=' a multiplicative factor to plotted field')17 parser.add_option('--mult', action='store',dest='mult', type="float", default=1., help='multiplicative factor to plotted field (2718=log)') 18 18 parser.add_option('-m', '--min', action='append',dest='vmin', type="float", default=None, help='bounding minimum value [min]') 19 19 parser.add_option('-M', '--max', action='append',dest='vmax', type="float", default=None, help='bounding maximum value [max]') -
trunk/UTIL/PYTHON/planetoplot.py
r507 r516 342 342 what_I_plot, error = reducefield( all_var[index_f], d4=indextime, d1=indexlon, d2=indexlat, d3=indexvert, \ 343 343 yint=yintegral, alt=vert, anomaly=anomaly, redope=redope ) 344 what_I_plot = what_I_plot*mult 344 if mult != 2718.: what_I_plot = what_I_plot*mult 345 else: what_I_plot = np.log10(what_I_plot) ; print "log plot" 345 346 if var2: ### what is contoured. 346 347 what_I_plot_contour, error = reducefield( all_var2[index_f], d4=indextime, d1=indexlon, d2=indexlat , d3=indexvert, \ … … 446 447 if mrate is not None: x = y ## because swapaxes... 447 448 #what_I_plot_frame = np.diff(what_I_plot_frame, n=1) ; x = x[1:] 448 if indexvert is not None or indextime is None: plot(x,what_I_plot_frame,label=lbl) ## regular plot 449 else: plot(what_I_plot_frame,x,label=lbl) ## vertical profile 449 450 if not tile: zeline='-' 451 else: zeline=',' 452 if indexvert is not None or indextime is None: plot(x,what_I_plot_frame,zeline,label=lbl) ## regular plot 453 else: plot(what_I_plot_frame,x,zeline,label=lbl) ## vertical profile 450 454 if nplot > 1: legend(loc='best') 451 455 if indextime is None and axtime is not None and xlab is None: xlabel(axtime.upper()) ## define the right label … … 469 473 elif mult != 1: daformat = "%.1f" 470 474 else: daformat = fmtvar(fvar.upper()) 471 colorbar( fraction=0.05,pad=0.03,format=daformat,\ 475 if proj in ['moll']: zeorientation="horizontal" 476 else: zeorientation="vertical" 477 zecb = colorbar( fraction=0.05,pad=0.03,format=daformat,orientation=zeorientation,\ 472 478 ticks=np.linspace(zevmin,zevmax,num=min([ticks/2+1,21])),extend='neither',spacing='proportional' ) 479 if zeorientation == "horizontal": 480 zecb.ax.set_xlabel(zetitle) 481 zetitle="" 473 482 if winds: 474 483 if typefile in ['mesoapi','meso']:
Note: See TracChangeset
for help on using the changeset viewer.