source: lmdz_wrf/trunk/tools/documentation/plotting/Nlines_time.html @ 1553

Last change on this file since 1553 was 1489, checked in by lfita, 8 years ago

Improving `draw_lines_time':

  • Including '*' for no label in legend
  • Fixing some text in graph by introducing `latex_text'
File size: 6.6 KB
Line 
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      Nlines time
11    </DIV>
12    <DIV CLASS="valimg">
13      Plotting a series of multiples 1D curves which share one time-dimension
14      <IMG WIDTH="100%" SRC="figs/lines_time.png"></IMG>
15    </DIV>
16    <DIV CLASS="valhelp">
17    draw_lines_time(ncfilens, values, varnames):<BR>
18    &nbsp;&nbsp;ncfilens= [filen] ',' separated list of netCDF files<BR>
19    &nbsp;&nbsp;values= [dimvname];[valuesaxis];[dimtit];[dimxyfmt];[leglabels];[vtit];[title];[rangevals];[timevals];<BR>
20    &nbsp;&nbsp;&nbsp;&nbsp;[legvals];[graphk];[collines];[points];[linewidths];[pointsizes];[pointfreq];[period];[close]<BR>
21    &nbsp;&nbsp;&nbsp;&nbsp;[dimvname]: ',' list of names of the variables with he values of the common dimension ('WRFtime' for WRF Times variable)<BR>
22    &nbsp;&nbsp;&nbsp;&nbsp;[valuesaxis]: which axis will be used for the values ('x', or 'y')<BR>
23    &nbsp;&nbsp;&nbsp;&nbsp;[dimtit]: title for the common dimension ('|' for spaces)<BR>
24    &nbsp;&nbsp;&nbsp;&nbsp;[dimxyfmt]=[dxs],[dxf],[Ndx],[ordx],[dys],[dyf],[Ndy],[ordx]: format of the values at each axis (or 'auto')<BR>
25    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[dxs]: style of x-axis ('auto' for 'pretty')<BR>
26    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'Nfix', values computed at even 'Ndx'<BR>
27    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'Vfix', values computed at even 'Ndx' increments<BR>
28    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'pretty', values computed following aprox. 'Ndx' at 'pretty' intervals (2.,2.5,4,5,10)<BR>
29    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[dxf]: format of the labels at the x-axis ('auto' for '%5g')<BR>
30    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[Ndx]: Number of ticks at the x-axis ('auto' for 5)<BR>
31    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[ordx]: angle of orientation of ticks at the x-axis ('auto' for horizontal)<BR>
32    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[dys]: style of y-axis ('auto' for 'pretty')<BR>
33    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[dyf]: format of the labels at the y-axis ('auto' for '%5g')<BR>
34    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[Ndy]: Number of ticks at the y-axis ('auto' for 5)<BR>
35    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[ordy]: angle of orientation of ticks at the y-axis ('auto' for horizontal)<BR>
36    &nbsp;&nbsp;&nbsp;&nbsp;[leglabels]: ',' separated list of names for the legend ('None', no legend '!' for spaces, '*' for no label)<BR>
37    &nbsp;&nbsp;&nbsp;&nbsp;[vartit]: name of the variable in the graph<BR>
38    &nbsp;&nbsp;&nbsp;&nbsp;[title]: title of the plot ('|' for spaces)<BR>
39    &nbsp;&nbsp;&nbsp;&nbsp;[rangevals]: Range of the axis with the values ('None' for 'auto','auto')<BR>
40    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[vmin],[vmax]: minimum and maximum values where [vmNN] can also be:<BR>
41    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'auto': the computed minimumm or maximum of the values  <BR>
42    &nbsp;&nbsp;&nbsp;&nbsp;[timevals]: [timen]|[units]|[kind]|[tfmt] time labels characteristics<BR>
43    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[timen]; name of the time variable<BR>
44    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[units]; units string according to CF conventions ([tunits] since <BR>
45    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[YYYY]-[MM]-[DD] [[HH]:[MI]:[SS]], '!' for spaces)<BR>
46    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[kind]; kind of output<BR>
47    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'Nval': according to a given number of values as 'Nval',[Nval]<BR>
48    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'exct': according to an exact time unit as 'exct',[tunit]; <BR>
49    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;tunit= [Nunits],[tu]; [tu]= 'c': centuries, 'y': year, 'm': month,<BR>
50    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'w': week, 'd': day, 'h': hour, 'i': minute, 's': second, <BR>
51    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'l': milisecond<BR>
52    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[tfmt]; desired format<BR>
53    &nbsp;&nbsp;&nbsp;&nbsp;[legvals]=[locleg]|[fontsize]: <BR>
54    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[locleg]: location of the legend (0, autmoatic)<BR>
55    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1: 'upper right', 2: 'upper left', 3: 'lower left', 4: 'lower right',<BR>
56    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;5: 'right', 6: 'center left', 7: 'center right', 8: 'lower center',<BR>
57    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;9: 'upper center', 10: 'center'<BR>
58    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[fontsize]: font size for the legend (auto for 12)<BR>
59    &nbsp;&nbsp;&nbsp;&nbsp;[graphk]: kind of the graphic<BR>
60    &nbsp;&nbsp;&nbsp;&nbsp;[lines]: ',' list of type of lines, None for automatic, single value all the same<BR>
61    &nbsp;&nbsp;&nbsp;&nbsp;[collines]: ',' list of colors for the lines, None for automatic, single <BR>
62    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;value all the same<BR>
63    &nbsp;&nbsp;&nbsp;&nbsp;[points]: '@' list of type of points for the lines, None for automatic, single<BR>
64    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;value all the same<BR>
65    &nbsp;&nbsp;&nbsp;&nbsp;[linewidths]: ',' list of widths for the lines, None for automatic, single<BR>
66    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;value all the same<BR>
67    &nbsp;&nbsp;&nbsp;&nbsp;[pointsizes]: ',' list of widths for the lines, None for automatic, single<BR>
68    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;value all the same<BR>
69    &nbsp;&nbsp;&nbsp;&nbsp;[pointfreq]: frequency of point plotting, 'all' for all time steps<BR>
70    &nbsp;&nbsp;&nbsp;&nbsp;[period]: which period to plot<BR>
71    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'-1': all period<BR>
72    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[beg],[end]: beginning and end of the period in reference time-units of first file<BR>
73    &nbsp;&nbsp;&nbsp;&nbsp;[close]: Whether figure should be finished or not<BR>
74    &nbsp;&nbsp;varnames= ',' list of variable names to plot (assuming only 1 variable per file)<BR>
75    </DIV>
76    <DIV CLASS="valins">
77      $ python ${pyHOME}/drawing.py -o draw_lines_time -f wrfout_d01_2001-11-11_00:00:00_west_east_B20-E20-I1_south_north_B20-E20-I1.nc,wrfout_d01_2001-11-11_00:00:00_west_east_B25-E25-I1_south_north_B25-E25-I1.nc,wrfout_d01_2001-11-11_00:00:00_west_east_B35-E35-I1_south_north_B35-E35-I1.nc -S 'WRFtime;y;time ([DD]${[HH]}$);auto;we=20$\times$sn=20,we=25$\times$sn=25,we=35$\times$sn=35;tas;tas|evolution|at|3|different|grid|points;None;time|hours!since!1949-12-01_00:00:00|exct,3,h|%d$^{%H}$;0|12;png;-;r,g,b;.;2.;2.;all;-1;True' -v T2
78    </DIV>
79  </BODY>
80</HTML>
81
Note: See TracBrowser for help on using the repository browser.