1 | <HTML> |
---|
2 | <HEAD> |
---|
3 | <META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=utf-8"/> |
---|
4 | <LINK REL="stylesheet" TYPE="text/css" HREF="../PyNCplot.css"/> |
---|
5 | </HEAD> |
---|
6 | |
---|
7 | </HEAD> |
---|
8 | <BODY> |
---|
9 | <DIV CLASS="valheader"> |
---|
10 | 2D shadow plot |
---|
11 | </DIV> |
---|
12 | <DIV CLASS="valimg"> |
---|
13 | Plotting a 2D field with shading |
---|
14 | <IMG WIDTH="100%" SRC="figs/multi_2Dfields_shadow.png"></IMG> |
---|
15 | </DIV> |
---|
16 | <DIV CLASS="valhelp"> |
---|
17 | draw_2D_shad(ncfiles, values, varn)<BR> |
---|
18 | ncfiles= ';' list of files to use as [filen]@[varn]@[dimvals]<BR> |
---|
19 | [filen]: name of the file<BR> |
---|
20 | [varn]: name of the variable in the file to be shaded<BR> |
---|
21 | [dimvals]: ',' list of [dimname]|[value] telling at which dimension of the <BR> |
---|
22 | variable a given value is required:<BR> |
---|
23 | * [integer]: which value of the dimension<BR> |
---|
24 | * -1: all along the dimension<BR> |
---|
25 | * -9: last value of the dimension<BR> |
---|
26 | * [beg]@[end]@[inc] slice from [beg] to [end] every [inc]<BR> |
---|
27 | * NOTE, no dim name all the dimension size<BR> |
---|
28 | values=[vnamefs]:[dimxvn]:[dimyvn]:[dimxyfmt]:[colorbarvals]:[sminv],[smaxv]:<BR> |
---|
29 | [kindfig]:[reverse]:[mapv]:[labels]:[Nrow]:[Ncol]:[globaltitle]:[close]<BR> |
---|
30 | [dimx/yvn]: name of the variables with the values of the final dimensions (x,y)<BR> |
---|
31 | [dimxyfmt]=[dxs],[dxf],[Ndx],[ordx],[dys],[dyf],[Ndy],[ordx]: format of the values at each axis (or 'auto')<BR> |
---|
32 | [dxs]: style of x-axis ('auto' for 'pretty')<BR> |
---|
33 | 'Nfix', values computed at even 'Ndx'<BR> |
---|
34 | 'Vfix', values computed at even 'Ndx' increments<BR> |
---|
35 | 'pretty', values computed following aprox. 'Ndx' at 'pretty' intervals (2.,2.5,4,5,10)<BR> |
---|
36 | [dxf]: format of the labels at the x-axis ('auto' for '%5g')<BR> |
---|
37 | [Ndx]: Number of ticks at the x-axis ('auto' for 5)<BR> |
---|
38 | [ordx]: angle of orientation of ticks at the x-axis ('auto' for horizontal)<BR> |
---|
39 | [dys]: style of y-axis ('auto' for 'pretty')<BR> |
---|
40 | [dyf]: format of the labels at the y-axis ('auto' for '%5g')<BR> |
---|
41 | [Ndy]: Number of ticks at the y-axis ('auto' for 5)<BR> |
---|
42 | [ordy]: angle of orientation of ticks at the y-axis ('auto' for horizontal)<BR> |
---|
43 | [colorbarvals]=[colbarn],[fmtcolorbar],[orientation]<BR> |
---|
44 | [colorbarn]: name of the color bar<BR> |
---|
45 | [fmtcolorbar]: format of the numbers in the color bar 'C'-like ('auto' for %6g)<BR> |
---|
46 | [orientation]: orientation of the colorbar ('vertical' (default, by 'auto'), 'horizontal')<BR> |
---|
47 | [smin/axv]: minimum and maximum value for the shading or:<BR> |
---|
48 | 'Srange': for full range<BR> |
---|
49 | 'Saroundmean@val': for mean-xtrm,mean+xtrm where xtrm = np.min(mean-min@val,max@val-mean)<BR> |
---|
50 | 'Saroundminmax@val': for min*val,max*val<BR> |
---|
51 | 'Saroundpercentile@val': for median-xtrm,median+xtrm where xtrm = np.min(median-percentile_(val),<BR> |
---|
52 | percentile_(100-val)-median)<BR> |
---|
53 | 'Smean@val': for -xtrm,xtrm where xtrm = np.min(mean-min*@val,max*@val-mean)<BR> |
---|
54 | 'Smedian@val': for -xtrm,xtrm where xtrm = np.min(median-min@val,max@val-median)<BR> |
---|
55 | 'Spercentile@val': for -xtrm,xtrm where xtrm = np.min(median-percentile_(val),<BR> |
---|
56 | percentile_(100-val)-median)<BR> |
---|
57 | [kindfig]: kind of figure output file: png, pdf, ...<BR> |
---|
58 | [reverse]: Transformation of the values<BR> |
---|
59 | * 'transpose': reverse the axes (x-->y, y-->x)<BR> |
---|
60 | * 'flip'@[x/y]: flip the axis x or y<BR> |
---|
61 | [mapv]: map characteristics: [proj],[res]<BR> |
---|
62 | see full documentation: <HREF CLASS="lc" HREF="http://matplotlib.org/basemap" TARGET="_blank">http://matplotlib.org/basemap</A><BR> |
---|
63 | [proj]: projection<BR> |
---|
64 | * 'cyl', cilindric<BR> |
---|
65 | * 'lcc', lambert conformal<BR> |
---|
66 | [res]: resolution:<BR> |
---|
67 | * 'c', crude<BR> |
---|
68 | * 'l', low<BR> |
---|
69 | * 'i', intermediate<BR> |
---|
70 | * 'h', high<BR> |
---|
71 | * 'f', full<BR> |
---|
72 | [labels]: ',' list of consecutive labels for each individual panel ('!' for spaces) |
---|
73 | [Nrow]: number of rows in the figure |
---|
74 | [Ncol]: number of columns in the figure |
---|
75 | [globaltitle]: global title of the figure ('!' for spaces) |
---|
76 | [close]: Whether figure should be finished or not<BR> |
---|
77 | </DIV> |
---|
78 | <DIV CLASS="valins"> |
---|
79 | python ${pyHOME}/drawing.py -o draw_multi_2D_shad -f '../PY/wrfout_d01_1995-01-01_00:00:00@T2@west_east|<BR> |
---|
80 | -1,south_north|-1,Time|0;../PY/wrfout_d01_1995-01-01_00:00:00@T2@west_east|-1,south_north|-1,Time|1;<BR> |
---|
81 | ../PY/wrfout_d01_1995-01-01_00:00:00@T2@west_east|-1,south_north|-1,Time|2;../PY/wrfout_d01_1995-01<BR> |
---|
82 | -01_00:00:00@T2@west_east|-1,south_north|-1,Time|3' -S 'tas:XLONG:XLAT:auto:rainbow,auto,auto:<BR> |
---|
83 | Srange,Srange:png:None:cyl,l:0!UTC,1!UTC,2!UTC,3!UTC:2:2:tas!at!2001-11-11:True' |
---|
84 | </DIV> |
---|
85 | </BODY> |
---|
86 | </HTML> |
---|
87 | |
---|