Ignore:
Timestamp:
08/10/06 09:01:35 (18 years ago)
Author:
smasson
Message:

introduce pltv.pro

Location:
trunk/SRC/ToBeReviewed/PLOTS
Files:
1 added
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/SRC/ToBeReviewed/PLOTS/DESSINE/plt.pro

    r142 r152  
    55; 
    66; @file_comments  
    7 ; Draw horizontal graph (map) 
     7; Draw horizontal graph (map) with CONTOUR procedure 
    88; 
    99; @categories  
     
    1111; 
    1212; @param TAB1 {in}{required}  
    13 ; The field whose we want to make the horizontal map can be 2 kind of thing: 
     13; The field whose we want to make the horizontal map can be: 
    1414;         1) an array. if needed, its mean along the z and t direction 
    1515;         will be automatically performed. 
     
    120120; 
    121121; @keyword MAXIN  
    122 ; Allows to specify the max value we want to consider in the drawing of contour  
    123 ; helping by the keyword instead of the argument max. If the argument and the keyword are  
    124 ; specified in the same time, it is the value specified by the keyword which is retained. 
     122; to specify the max value we want to plot with a keyword instead of with the 
     123; input parameter max. If max is defined by both, parameter and keyword, the 
     124; keyword is retained. 
    125125; 
    126126; @keyword MININ  
    127 ; Allows to specify the min value we want to consider in the drawing of contour  
    128 ; helping by the keyword instead of the argument min. If the argument and the keyword are  
    129 ; specified in the same time, it is the value specified by the keyword which is retained. 
     127; to specify the min value we want to plot with a keyword instead of with the 
     128; input parameter min. If min is defined by both, parameter and keyword, the 
     129; keyword is retained. 
    130130; 
    131131; @keyword NLEVEL  
  • trunk/SRC/ToBeReviewed/PLOTS/DESSINE/pltt.pro

    r142 r152  
    115115; 
    116116; @keyword MAXIN  
    117 ; Allows to specify the max value we want to consider in the drawing of contour  
    118 ; helping by the keyword instead of the argument max. If the argument and the keyword are  
    119 ; specified in the same time, it is the value specified by the keyword which is retained. 
     117; to specify the max value we want to plot with a keyword instead of with the 
     118; input parameter max. If max is defined by both, parameter and keyword, the 
     119; keyword is retained. 
    120120; 
    121121; @keyword MININ  
    122 ; Allows to specify the min value we want to consider in the drawing of contour  
    123 ; helping by the keyword instead of the argument min. If the argument and the keyword are  
    124 ; specified in the same time, it is the value specified by the keyword which is retained. 
     122; to specify the min value we want to plot with a keyword instead of with the 
     123; input parameter min. If min is defined by both, parameter and keyword, the 
     124; keyword is retained. 
    125125; 
    126126; @keyword NLEVEL  
  • trunk/SRC/ToBeReviewed/PLOTS/DESSINE/pltz.pro

    r142 r152  
    9797; 
    9898; @keyword MAXIN  
    99 ; Allows to specify the max value we want to consider in the drawing of contour  
    100 ; helping by the keyword instead of the argument max. If the argument and the keyword are  
    101 ; specified in the same time, it is the value specified by the keyword which is retained. 
     99; to specify the max value we want to plot with a keyword instead of with the 
     100; input parameter max. If max is defined by both, parameter and keyword, the 
     101; keyword is retained. 
    102102; 
    103103; @keyword MININ  
    104 ; Allows to specify the min value we want to consider in the drawing of contour  
    105 ; helping by the keyword instead of the argument min. If the argument and the keyword are  
    106 ; specified in the same time, it is the value specified by the keyword which is retained. 
     104; to specify the min value we want to plot with a keyword instead of with the 
     105; input parameter min. If min is defined by both, parameter and keyword, the 
     106; keyword is retained. 
    107107; 
    108108; @keyword NLEVEL  
  • trunk/SRC/ToBeReviewed/PLOTS/DESSINE/tvplus.pro

    r142 r152  
    2424; are not coded for "scrolling window" case... 
    2525; 
    26 ; @keyword BOTTOM 
    27 ; The lowest color index of the colors to be loaded in 
    28 ; the bar. default is 0. 
    29 ; 
    30 ; @keyword C_NAN 
     26; @keyword BOTTOM {default=1} 
     27; The lowest color index of the colors to be used 
     28; 
     29; @keyword C_NAN {default=!d.n_colors < 255} 
    3130; The color number that should be used for the NaN values. 
    32 ; default value is !d.n_colors < 255 
    33 ; 
    34 ; @keyword C_MASK 
     31; 
     32; @keyword C_MASK {default=0} 
    3533; The color number that should be used for the mask values. 
    36 ; default value is 0 
    3734; 
    3835; @keyword OFFSET  
     
    4744; abs(mask)/10. This is necessary to avoid the rounding errors 
    4845; 
    49 ; @keyword MIN  
    50 ; Scalar used to specify the min value of the color bar. default is 0 
     46; @keyword MIN 
     47; Scalar used to specify the min value to be drawn. 
    5148; 
    5249; @keyword MAX 
    53 ; Scalar used to specify the max value of the color bar. default is !d.n_colors < 255 
    54 ; 
    55 ; @keyword NCOLORS 
    56 ; This is the number of colors in the color bar. default is !d.n_colors<255 -1 
     50; Scalar used to specify the max value to be drawn. 
     51; 
     52; @keyword NCOLORS {default=(d.n_colors < 256) - 1 - bottom} 
     53; number of colors to be used. 
    5754; 
    5855; @keyword NOINTERP 
    5956; Used this keyword if you don't whant that the values 
    60 ; are interpolated between 0 (or min) and !d.n_colors < 255 (or max). 
     57; are interpolated from BOTTOM using NCOLORS colors. 
    6158; This can be for example usefull when working on byte type arrays. 
    6259; 
     
    6865; default is window number 0. 
    6966; 
     67; @keyword _EXTRA 
     68; used to pass keywords to TV, PLOT, COLORBAR 
     69;  
    7070; @restrictions  
    7171; use your mouse to scan the array values... 
     
    112112;------------------------------------------------------------ 
    113113  ncolmax = !d.n_colors < 256 
    114   IF N_ELEMENTS(bottom) EQ 0 THEN bottom = 0 
    115   if NOT keyword_set(ncolors) then ncolors = ncolmax-bottom 
     114  IF N_ELEMENTS(bottom) EQ 0 THEN bottom = 1 
     115  if NOT keyword_set(ncolors) then ncolors = ncolmax - 1 - bottom 
    116116  topcol = (bottom+ncolors-1) < (ncolmax-1) 
    117117;------------------------------------------------------------ 
     
    177177    m = 1.*(ncolors-1)/(truemax-truemin) 
    178178    p = bottom-1.*truemin*m 
    179     arr = round(1.*m*arr+p)  
     179    arr = round(m*temporary(arr)+p)  
    180180  endif 
    181181; set c_nan for NaN values  
     
    188188    arr[masked] = c_mask < (ncolmax -1) 
    189189; use byte type to save memory 
    190   arr = byte(arr) 
     190  arr = byte(temporary(arr)) 
    191191; increase the size of the array in order to be displayed 
    192192; with the suitable size  
    193   arr = congridseb(arr, (size(arr))[1]*cellsize, (size(arr))[2]*cellsize) 
     193  szarr = size(arr, /dimensions) 
     194  arr = congrid(temporary(arr), szarr[0]*cellsize, szarr[1]*cellsize) 
    194195;------------------------------------------------------------ 
    195196; open a window with the correct size 
  • trunk/SRC/ToBeReviewed/PLOTS/DIVERS/barrecouleur.pro

    r142 r152  
    2727                  , NOCOLORBAR = nocolorbar, CB_TITLE = cb_title $ 
    2828                  , NOFILL = nofill, COLOR_c = color_c $ 
    29                   , min = min, max = max, divisions = divisions $ 
     29                  , MIN = min, MAX = max, divisions = divisions $ 
    3030                  , CB_SUBTITLE = cb_subtitle, POST = post, _extra = ex 
    3131;------------------------------------------------------------ 
  • trunk/SRC/ToBeReviewed/PLOTS/axe.pro

    r142 r152  
    172172;-------------------------------------------------------------- 
    173173   case coupe of 
     174      'pltv':BEGIN  
     175        dtasize = tempsmin 
     176         !x.range = [-0.5, dtasize[0] - 0.5] 
     177         !y.range = [-0.5, dtasize[1] - 0.5]  
     178         if keyword_set(reverse_x) then !x.range=reverse(!x.range) 
     179         if keyword_set(reverse_y) then !y.range=reverse(!y.range) 
     180         !x.title = 'nx' 
     181         !y.title = 'ny' 
     182      END 
    174183      'xy':BEGIN  
    175184         if keyword_set(reverse_x) then !x.range=[lon2,lon1] ELSE !x.range=[lon1,lon2] 
  • trunk/SRC/ToBeReviewed/PLOTS/legende.pro

    r142 r152  
    4949;------------------------------------------------------------ 
    5050;------------------------------------------------------------ 
    51 pro legende,mi,ma,coupe,CONTOUR = contour,ENDPOINTS = endpoints, DIREC = direc $ 
    52             , VECTLEGENDE = vectlegende $ 
    53             , INTERVALLE = intervalle, TYPE_YZ = type_yz, VARNAME2 = varname2 $ 
    54             , NPTS = npts, _EXTRA = ex 
     51pro legende, mi, ma, coupe, CONTOUR = contour, ENDPOINTS = endpoints, DIREC = direc $ 
     52             , VECTLEGENDE = vectlegende $ 
     53             , INTERVALLE = intervalle, TYPE_YZ = type_yz, VARNAME2 = varname2 $ 
     54             , NPTS = npts, _EXTRA = ex 
    5555; 
    5656  compile_opt idl2, strictarrsubs 
    5757; 
    5858@common 
    59    tempsun = systime(1)         ; pour key_performance 
    60 ;------------------------------------------------------------ 
    61    grille, -1, -1, -1, gdep, nx, ny, nz 
     59  tempsun = systime(1)          ; pour key_performance 
     60;------------------------------------------------------------ 
     61  grille, -1, -1, -1, gdep, nx, ny, nz 
    6262; 
    6363; English legends 
    6464; 
    65    fmt_mm = '(f12.2)' 
    66    fmt_bt = '(f7.1)' 
    67    colorf = '' 
    68    contourf = 'Contour plot,' 
    69    vecteurf = 'Vector norm  ' 
    70    expf = '' 
    71    datef = '   ' 
    72    fieldf = '   ' 
    73    depthf = '   ' 
    74    endpointsf = 'Diag. Section' 
    75    zonalf = '' 
    76    IF key_onearth THEN latintf = 'latitudes in ' ELSE latintf = 'j index in ' 
    77    timintf = 'time in ' 
    78    onf = ' - ' 
    79    depthf2 = 'Depth (m)' 
    80    Meridf = 'Zonal Mean  ' 
    81    IF key_onearth THEN lonintf = 'longitudes in ' ELSE lonintf = 'i in ' 
    82    hovxt = 'XT-plot   ' 
    83    diaghovxt = 'Diag. XT-plot   ' 
    84    depintf = 'depths in ' 
    85    timef = 'Time' 
    86    hovyt = 'YT-plot   ' 
    87    diaghovyt = 'Diag. YT-plot   ' 
    88    hovzt = 'ZT-plot   ' 
    89    hovt = '' 
    90    IF key_onearth THEN lontitle = 'Longitude' ELSE lontitle = 'i index' 
    91    IF key_onearth THEN lattitle = 'Latitude' ELSE lattitle = 'j index' 
    92     
    93    vertz = depthf2 
    94    legniv = ' m' 
    95    IF keyword_set(TYPE_YZ) THEN BEGIN 
    96      IF type_yz EQ 'hPa' THEN vertz = 'hPa'  
    97      IF type_yz EQ 'hPa' THEN legniv = ' hPa'  
    98    ENDIF  
     65  fmt_mm = '(f12.2)' 
     66  fmt_bt = '(f7.1)' 
     67  colorf = '' 
     68  contourf = 'Contour plot,' 
     69  vecteurf = 'Vector norm  ' 
     70  expf = '' 
     71  datef = '   ' 
     72  fieldf = '   ' 
     73  depthf = '   ' 
     74  endpointsf = 'Diag. Section' 
     75  zonalf = '' 
     76  IF key_onearth THEN latintf = 'latitudes in ' ELSE latintf = 'j index in ' 
     77  timintf = 'time in ' 
     78  onf = ' - ' 
     79  depthf2 = 'Depth (m)' 
     80  Meridf = 'Zonal Mean  ' 
     81  IF key_onearth THEN lonintf = 'longitudes in ' ELSE lonintf = 'i in ' 
     82  hovxt = 'XT-plot   ' 
     83  diaghovxt = 'Diag. XT-plot   ' 
     84  depintf = 'depths in ' 
     85  timef = 'Time' 
     86  hovyt = 'YT-plot   ' 
     87  diaghovyt = 'Diag. YT-plot   ' 
     88  hovzt = 'ZT-plot   ' 
     89  hovt = '' 
     90  IF key_onearth THEN lontitle = 'Longitude' ELSE lontitle = 'i index' 
     91  IF key_onearth THEN lattitle = 'Latitude' ELSE lattitle = 'j index' 
     92   
     93  vertz = depthf2 
     94  legniv = ' m' 
     95  IF keyword_set(TYPE_YZ) THEN BEGIN 
     96    IF type_yz EQ 'hPa' THEN vertz = 'hPa'  
     97    IF type_yz EQ 'hPa' THEN legniv = ' hPa'  
     98  ENDIF  
    9999; 
    100100; Start legende 
     
    103103; definition and possible complement of !p.subtitle 
    104104;------------------------------------------------------------ 
    105    if n_elements(varunit) ne 0 then unite='('+varunit+')' else unite='' 
    106    !p.subtitle=colorf+unite+': Min= '+strtrim(string(format=fmt_mm,mi), 2)$ 
    107     +', Max= '+strtrim(string(format=fmt_mm,ma), 2) 
    108    if keyword_set(intervalle) then BEGIN 
    109       if intervalle NE -1 then $ 
    110        !p.subtitle=!p.subtitle+', Int= '+strtrim(string(format=fmt_mm,intervalle), 2) 
    111    endif 
    112    if size(contour, /type) EQ 8 then BEGIN ; it is a structure  
    113       unite='('+contour.(1)+')' 
    114       !p.subtitle=!p.subtitle+'!C '+contourf+unite $ 
    115        +': Min= '+strtrim(string(format=fmt_mm,contour.(0)[0]), 2)$ 
    116        +', Max= '+strtrim(string(format=fmt_mm,contour.(0)[1]), 2) 
    117       if contour.inter NE -1  then $ 
    118        !p.subtitle=!p.subtitle+', Int= '+strtrim(string(format=fmt_mm,contour.inter), 2) 
    119    ENDIF 
    120    if size(vectlegende, /type) EQ 8  then begin 
    121       unite='('+vectlegende.(1)+')' 
    122       !p.subtitle=!p.subtitle+'!C '+vecteurf+unite $ 
    123        +': Min= '+strtrim(string(format=fmt_mm,vectlegende.(0)[0]), 2)$ 
    124        +', Max= '+strtrim(string(format=fmt_mm,vectlegende.(0)[1]), 2) 
    125    endif 
     105  if n_elements(varunit) ne 0 then unite = '('+varunit+')' else unite = '' 
     106  !p.subtitle = colorf+unite+': Min= '+strtrim(string(format = fmt_mm, mi), 2)$ 
     107                +', Max= '+strtrim(string(format = fmt_mm, ma), 2) 
     108  if keyword_set(intervalle) then BEGIN 
     109    if intervalle NE -1 then $ 
     110       !p.subtitle = !p.subtitle+', Int= '+strtrim(string(format = fmt_mm, intervalle), 2) 
     111  endif 
     112  if size(contour, /type) EQ 8 then BEGIN ; it is a structure  
     113    unite = '('+contour.(1)+')' 
     114    !p.subtitle = !p.subtitle+'!C '+contourf+unite $ 
     115                  +': Min= '+strtrim(string(format = fmt_mm, contour.(0)[0]), 2)$ 
     116                  +', Max= '+strtrim(string(format = fmt_mm, contour.(0)[1]), 2) 
     117    if contour.inter NE -1  then $ 
     118       !p.subtitle = !p.subtitle+', Int= '+strtrim(string(format = fmt_mm, contour.inter), 2) 
     119  ENDIF 
     120  if size(vectlegende, /type) EQ 8  then begin 
     121    unite = '('+vectlegende.(1)+')' 
     122    !p.subtitle = !p.subtitle+'!C '+vecteurf+unite $ 
     123                  +': Min= '+strtrim(string(format = fmt_mm, vectlegende.(0)[0]), 2)$ 
     124                  +', Max= '+strtrim(string(format = fmt_mm, vectlegende.(0)[1]), 2) 
     125  endif 
    126126;------------------------------------------------------------ 
    127127; Shapping of subdomain 's dimensions 
    128128;------------------------------------------------------------   
    129   la1=strtrim(string(format=fmt_bt, lat1), 2) 
    130    la2=strtrim(string(format=fmt_bt, lat2), 2) 
    131    lo1=strtrim(string(format=fmt_bt, lon1), 2) 
    132    lo2=strtrim(string(format=fmt_bt, lon2), 2) 
    133    pr1=strtrim(string(format=fmt_bt, vert1), 2) 
    134    pr2=strtrim(string(format=fmt_bt, vert2), 2) 
     129  la1 = strtrim(string(format = fmt_bt, lat1), 2) 
     130  la2 = strtrim(string(format = fmt_bt, lat2), 2) 
     131  lo1 = strtrim(string(format = fmt_bt, lon1), 2) 
     132  lo2 = strtrim(string(format = fmt_bt, lon2), 2) 
     133  pr1 = strtrim(string(format = fmt_bt, vert1), 2) 
     134  pr2 = strtrim(string(format = fmt_bt, vert2), 2) 
    135135;------------------------------------------------------------ 
    136136; Management of the date 
    137137;------------------------------------------------------------   
    138  if n_elements(vardate) EQ 0 then vardate = '' 
    139    if NOT keyword_set(direc) then direc = '' 
    140    if strpos(direc, 't') NE -1 then begin 
    141       svardate = strtrim(vairdate(time[0]), 1)+' - '+strtrim(vairdate(time[jpt-1]), 1) 
    142    ENDIF ELSE svardate = vardate 
     138  if n_elements(vardate) EQ 0 then vardate = '' 
     139  if NOT keyword_set(direc) then direc = '' 
     140  if strpos(direc, 't') NE -1 then begin 
     141    svardate = strtrim(vairdate(time[0]), 1)+' - '+strtrim(vairdate(time[jpt-1]), 1) 
     142  ENDIF ELSE svardate = vardate 
    143143;------------------------------------------------------------ 
    144144; case on the caes where the caption is applied 
    145145;------------------------------------------------------------    
    146    case coupe of 
    147       'xy':begin           
    148         if strupcase(vargrid) EQ 'W' then firstz = firstzw $ 
    149         ELSE firstz = firstzt 
    150         if(strpos(direc, 'z') EQ -1 AND firstz NE 0) then BEGIN 
    151           prof = strtrim(round(gdep[0]), 1) 
    152           !p.title = expf+varexp+datef+svardate+fieldf+varname+depthf+prof+legniv 
    153         ENDIF ELSE !p.title = expf+varexp+datef+svardate+fieldf+varname 
    154         !x.title = lontitle 
    155         !y.title = lattitle 
    156       end 
    157  
    158       'xz':begin 
    159          IF keyword_set(npts) THEN n = strtrim(npts, 1) ELSE n=strtrim(ny, 1) 
    160          IF long(n) LE 3 THEN zonalf = 'Section   ' 
    161          if keyword_set(endpoints) AND lat1 NE lat2 then $ 
    162           !p.title = endpointsf+varexp+datef+svardate+fieldf+varname ELSE $ 
    163           !p.title = zonalf+varexp+datef+svardate+fieldf+varname 
    164          !x.title = lontitle 
    165          if keyword_set(endpoints) AND lat1 EQ lat2 then BEGIN  
    166            IF key_onearth THEN !x.title = !x.title+' at '+strtrim(lataxe(0, 0, lat1), 1) ELSE !x.title = !x.title+' at j index '+strtrim(lat1, 1) 
    167          ENDIF 
    168          !y.title = depthf2 
    169       end 
    170  
    171       'yz':begin 
    172          IF keyword_set(npts) THEN n = strtrim(npts, 1) ELSE n=strtrim(nx, 1) 
    173          IF long(n) LE 3 THEN meridf = '' 
    174          if keyword_set(endpoints) AND lon1 NE lon2 then $ 
    175           !p.title = endpointsf+varexp+datef+svardate+fieldf+varname ELSE $ 
    176           !p.title = meridf+varexp+datef+svardate+fieldf+varname 
    177          !y.title = vertz 
    178          !x.title = lattitle 
    179          if keyword_set(endpoints) AND lon1 EQ lon2 then BEGIN  
    180            IF key_onearth THEN !x.title = !x.title+' at '+strtrim(lonaxe(0, 0, lon1), 1) ELSE !x.title = !x.title+' at i index '+strtrim(lon1, 1) 
    181          ENDIF 
    182       end 
    183  
    184       'xt':begin 
     146  case coupe of 
     147    'xy':begin           
     148      if strupcase(vargrid) EQ 'W' then firstz = firstzw $ 
     149      ELSE firstz = firstzt 
     150      if(strpos(direc, 'z') EQ -1 AND firstz NE 0) then BEGIN 
     151        prof = strtrim(round(gdep[0]), 1) 
     152        !p.title = expf+varexp+datef+svardate+fieldf+varname+depthf+prof+legniv 
     153      ENDIF ELSE !p.title = expf+varexp+datef+svardate+fieldf+varname 
     154      !x.title = lontitle 
     155      !y.title = lattitle 
     156    end 
     157 
     158    'xz':begin 
     159      IF keyword_set(npts) THEN n = strtrim(npts, 1) ELSE n = strtrim(ny, 1) 
     160      IF long(n) LE 3 THEN zonalf = 'Section   ' 
     161      if keyword_set(endpoints) AND lat1 NE lat2 then $ 
     162         !p.title = endpointsf+varexp+datef+svardate+fieldf+varname ELSE $ 
     163            !p.title = zonalf+varexp+datef+svardate+fieldf+varname 
     164      !x.title = lontitle 
     165      if keyword_set(endpoints) AND lat1 EQ lat2 then BEGIN  
     166        IF key_onearth THEN !x.title = !x.title+' at '+strtrim(lataxe(0, 0, lat1), 1) ELSE !x.title = !x.title+' at j index '+strtrim(lat1, 1) 
     167      ENDIF 
     168      !y.title = depthf2 
     169    end 
     170 
     171    'yz':begin 
     172      IF keyword_set(npts) THEN n = strtrim(npts, 1) ELSE n = strtrim(nx, 1) 
     173      IF long(n) LE 3 THEN meridf = '' 
     174      if keyword_set(endpoints) AND lon1 NE lon2 then $ 
     175         !p.title = endpointsf+varexp+datef+svardate+fieldf+varname ELSE $ 
     176            !p.title = meridf+varexp+datef+svardate+fieldf+varname 
     177      !y.title = vertz 
     178      !x.title = lattitle 
     179      if keyword_set(endpoints) AND lon1 EQ lon2 then BEGIN  
     180        IF key_onearth THEN !x.title = !x.title+' at '+strtrim(lonaxe(0, 0, lon1), 1) ELSE !x.title = !x.title+' at i index '+strtrim(lon1, 1) 
     181      ENDIF 
     182    end 
     183 
     184    'xt':begin 
    185185;         IF keyword_set(npts) THEN n = strtrim(npts, 1) 
    186          if keyword_set(endpoints) AND lat1 NE lat2 then $ 
    187           !p.title = diaghovxt+varexp+fieldf+varname ELSE $ 
    188          !p.title  =     hovxt+varexp+fieldf+varname 
    189          IF (time[(size(time))[0]-1] - time[0]) GE 10 THEN !y.title = timef 
    190          !x.title = lontitle 
    191          if keyword_set(endpoints) AND lat1 EQ lat2 then BEGIN  
    192            IF key_onearth THEN !x.title = !x.title+' at '+strtrim(lataxe(0, 0, lat1), 1) ELSE !x.title = !x.title+' at j index '+strtrim(lat1, 1) 
    193          ENDIF 
    194       end 
    195  
    196       'yt':begin 
     186      if keyword_set(endpoints) AND lat1 NE lat2 then $ 
     187         !p.title = diaghovxt+varexp+fieldf+varname ELSE $ 
     188            !p.title  =     hovxt+varexp+fieldf+varname 
     189      IF (time[(size(time))[0]-1] - time[0]) GE 10 THEN !y.title = timef 
     190      !x.title = lontitle 
     191      if keyword_set(endpoints) AND lat1 EQ lat2 then BEGIN  
     192        IF key_onearth THEN !x.title = !x.title+' at '+strtrim(lataxe(0, 0, lat1), 1) ELSE !x.title = !x.title+' at j index '+strtrim(lat1, 1) 
     193      ENDIF 
     194    end 
     195 
     196    'yt':begin 
    197197;         IF keyword_set(npts) THEN n = strtrim(npts, 1)  
    198          if keyword_set(endpoints) AND lon1 NE lon2 then $ 
    199           !p.title = diaghovyt+varexp+fieldf+varname ELSE $ 
    200          !p.title  =     hovyt+varexp+fieldf+varname 
    201          IF (time[(size(time))[0]-1] - time[0]) GE 10 THEN !x.title = timef 
    202          !y.title = lattitle 
    203          if keyword_set(endpoints) AND lon1 EQ lon2 then BEGIN  
    204            IF key_onearth THEN !x.title = !x.title+' at '+strtrim(lonaxe(0, 0, lon1), 1) ELSE !x.title = !x.title+' at i index '+strtrim(lon1, 1) 
    205          ENDIF 
    206       end 
    207  
    208       'zt':begin 
     198      if keyword_set(endpoints) AND lon1 NE lon2 then $ 
     199         !p.title = diaghovyt+varexp+fieldf+varname ELSE $ 
     200            !p.title  =     hovyt+varexp+fieldf+varname 
     201      IF (time[(size(time))[0]-1] - time[0]) GE 10 THEN !x.title = timef 
     202      !y.title = lattitle 
     203      if keyword_set(endpoints) AND lon1 EQ lon2 then BEGIN  
     204        IF key_onearth THEN !x.title = !x.title+' at '+strtrim(lonaxe(0, 0, lon1), 1) ELSE !x.title = !x.title+' at i index '+strtrim(lon1, 1) 
     205      ENDIF 
     206    end 
     207 
     208    'zt':begin 
    209209;         IF keyword_set(npts) THEN n = strtrim(npts, 1) ELSE n=strtrim(nx*ny, 1) 
    210          !p.title = hovzt+varexp+fieldf+varname 
    211          !y.title = depthf2 
    212          IF (time[(size(time))[0]-1] - time[0]) GE 10 THEN !x.title = timef 
    213       end 
    214       't':begin 
     210      !p.title = hovzt+varexp+fieldf+varname 
     211      !y.title = depthf2 
     212      IF (time[(size(time))[0]-1] - time[0]) GE 10 THEN !x.title = timef 
     213    end 
     214    't':begin 
    215215;         IF keyword_set(npts) THEN n = strtrim(npts, 1) ELSE BEGIN  
    216216;            if keyword_set(integration3d) then n=strtrim(nx*ny*nz, 1) ELSE n=strtrim(nx*ny, 1) 
    217217;         ENDELSE  
    218          !p.title = hovt+varexp+fieldf+varname 
    219          !y.title = varname 
    220          IF (time[(size(time))[0]-1] - time[0]) GE 10 THEN !x.title = timef 
    221       end 
    222       'x':begin             
     218      !p.title = hovt+varexp+fieldf+varname 
     219      !y.title = varname 
     220      IF (time[(size(time))[0]-1] - time[0]) GE 10 THEN !x.title = timef 
     221    end 
     222    'x':begin             
    223223;         IF keyword_set(npts) THEN n = strtrim(npts, 1) ELSE n=strtrim(ny*nz, 1) 
    224          if keyword_set(endpoints) AND lat1 NE lat2 then $ 
    225           !p.title = endpointsf+varexp+datef+svardate+fieldf+varname ELSE $ 
    226          !p.title  =            varexp+datef+svardate+fieldf+varname 
    227          !x.title = lontitle 
    228          if keyword_set(endpoints) AND lat1 EQ lat2 then BEGIN  
    229            IF key_onearth THEN !x.title = !x.title+' at '+strtrim(lataxe(0, 0, lat1), 1) ELSE !x.title = !x.title+' at j index '+strtrim(lat1, 1) 
    230          ENDIF 
    231          !y.title = varname 
    232       end 
    233       'y':begin             
     224      if keyword_set(endpoints) AND lat1 NE lat2 then $ 
     225         !p.title = endpointsf+varexp+datef+svardate+fieldf+varname ELSE $ 
     226            !p.title  =            varexp+datef+svardate+fieldf+varname 
     227      !x.title = lontitle 
     228      if keyword_set(endpoints) AND lat1 EQ lat2 then BEGIN  
     229        IF key_onearth THEN !x.title = !x.title+' at '+strtrim(lataxe(0, 0, lat1), 1) ELSE !x.title = !x.title+' at j index '+strtrim(lat1, 1) 
     230      ENDIF 
     231      !y.title = varname 
     232    end 
     233    'y':begin             
    234234;         IF keyword_set(npts) THEN n = strtrim(npts, 1) ELSE n=strtrim(nx*nz, 1) 
    235          if keyword_set(endpoints) AND lon1 NE lon2 then $ 
    236           !p.title = endpointsf+varexp+datef+svardate+fieldf+varname ELSE $ 
    237          !p.title  =            varexp+datef+svardate+fieldf+varname 
    238          !x.title = lattitle 
    239          if keyword_set(endpoints) AND lon1 EQ lon2 then BEGIN  
    240            IF key_onearth THEN !x.title = !x.title+' at '+strtrim(lonaxe(0, 0, lon1), 1) ELSE !x.title = !x.title+' at i index '+strtrim(lon1, 1) 
    241          ENDIF 
    242          !y.title = varname 
    243       end 
    244       'z':begin 
    245          IF keyword_set(npts) THEN n = strtrim(npts, 1) ELSE n=strtrim(nx*ny, 1) 
    246          !p.title = varexp+datef+svardate+fieldf+varname 
    247          !y.title = depthf2 
    248          !x.title = varname 
    249       end 
    250       'yfx': BEGIN 
    251          IF keyword_set(npts) THEN n = strtrim(npts, 1) ELSE n=strtrim(nx*ny*nz, 1) 
    252          !p.title = varexp+datef+svardate+varunit 
    253          !x.title = varname2 
    254          !y.title = varname 
    255       END  
    256       else: 
    257    ENDCASE 
    258    if keyword_set(direc) then BEGIN 
    259       if strpos(direc, 'x') NE -1 then $ 
     235      if keyword_set(endpoints) AND lon1 NE lon2 then $ 
     236         !p.title = endpointsf+varexp+datef+svardate+fieldf+varname ELSE $ 
     237            !p.title  =            varexp+datef+svardate+fieldf+varname 
     238      !x.title = lattitle 
     239      if keyword_set(endpoints) AND lon1 EQ lon2 then BEGIN  
     240        IF key_onearth THEN !x.title = !x.title+' at '+strtrim(lonaxe(0, 0, lon1), 1) ELSE !x.title = !x.title+' at i index '+strtrim(lon1, 1) 
     241      ENDIF 
     242      !y.title = varname 
     243    end 
     244    'z':begin 
     245      IF keyword_set(npts) THEN n = strtrim(npts, 1) ELSE n = strtrim(nx*ny, 1) 
     246      !p.title = varexp+datef+svardate+fieldf+varname 
     247      !y.title = depthf2 
     248      !x.title = varname 
     249    end 
     250    'yfx': BEGIN 
     251      IF keyword_set(npts) THEN n = strtrim(npts, 1) ELSE n = strtrim(nx*ny*nz, 1) 
     252      !p.title = varexp+datef+svardate+varunit 
     253      !x.title = varname2 
     254      !y.title = varname 
     255    END  
     256    else: 
     257  ENDCASE 
     258  if keyword_set(direc) then BEGIN 
     259    if strpos(direc, 'x') NE -1 then $ 
    260260       !p.subtitle = lonintf+'['+lo1+', '+lo2+']'+onf+'('+strtrim(nx, 1)+' points)  !C' +!p.subtitle 
    261       if strpos(direc, 'y') NE -1 then BEGIN 
    262          if strpos(!p.subtitle, '[') EQ -1 then $ 
    263           !p.subtitle = latintf+'['+la1+', '+la2+']'+onf+'('+strtrim(ny, 1)+' points)  !C'+!p.subtitle $ 
    264          ELSE !p.subtitle = latintf+'['+la1+', '+la2+']'+onf+'('+strtrim(ny, 1)+' points)  '+!p.subtitle 
    265       ENDIF 
    266       if strpos(direc, 'z') NE -1 AND (nz NE 1 OR coupe NE 'xy') then BEGIN  
    267          if strpos(!p.subtitle, '[') EQ -1 then $ 
    268           !p.subtitle = depintf+'['+pr1+', '+pr2+']'+onf+'('+strtrim(nz, 1)+' points)  !C'+!p.subtitle $ 
    269          ELSE !p.subtitle = depintf+'['+pr1+', '+pr2+']'+onf+'('+strtrim(nz, 1)+' points)  '+!p.subtitle 
    270       ENDIF 
    271    ENDIF 
    272    if keyword_set(endpoints) AND coupe NE 'yt' AND lat1 NE lat2 then !p.title = !p.title+'!C!C' 
    273     
    274    if keyword_set(key_performance) THEN print, 'temps legende', systime(1)-tempsun  
    275    return 
     261    if strpos(direc, 'y') NE -1 then BEGIN 
     262      if strpos(!p.subtitle, '[') EQ -1 then $ 
     263         !p.subtitle = latintf+'['+la1+', '+la2+']'+onf+'('+strtrim(ny, 1)+' points)  !C'+!p.subtitle $ 
     264      ELSE !p.subtitle = latintf+'['+la1+', '+la2+']'+onf+'('+strtrim(ny, 1)+' points)  '+!p.subtitle 
     265    ENDIF 
     266    if strpos(direc, 'z') NE -1 AND (nz NE 1 OR coupe NE 'xy') then BEGIN  
     267      if strpos(!p.subtitle, '[') EQ -1 then $ 
     268         !p.subtitle = depintf+'['+pr1+', '+pr2+']'+onf+'('+strtrim(nz, 1)+' points)  !C'+!p.subtitle $ 
     269      ELSE !p.subtitle = depintf+'['+pr1+', '+pr2+']'+onf+'('+strtrim(nz, 1)+' points)  '+!p.subtitle 
     270    ENDIF 
     271  ENDIF 
     272  if keyword_set(endpoints) AND coupe NE 'yt' AND lat1 NE lat2 then !p.title = !p.title+'!C!C' 
     273   
     274  if keyword_set(key_performance) THEN print, 'temps legende', systime(1)-tempsun  
     275  return 
    276276end 
Note: See TracChangeset for help on using the changeset viewer.