Changeset 36


Ignore:
Timestamp:
01/16/08 01:31:29 (16 years ago)
Author:
ericg
Message:

Added slope info in yfx plots

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/procs/legend_overlay.pro

    r18 r36  
    22                                ; domain_y = minc,maxc / 
    33                                ; domaint=time(0), time(jptmax-1) 
    4 IF debug_w THEN print, ' in legend_pltt_over, iover=', iover 
     4IF debug_w THEN print, ' in legend_overlay, iover=', iover 
    55; 
    66; decode legend format from command line (see def_work cmdi.proj) 
     
    1515; when there is more than one seasonal cycle 
    1616jptmax = jpt * nb_cycles 
    17 IF debug_w THEN print, 'jpt, jptmax, nb_cycles ', jpt,  jptmax, nb_cycles 
     17IF debug_w THEN print, 'leg_format, leg_pos: ', leg_format,  leg_pos 
     18IF debug_w THEN print, 'jpt, jptmax, nb_cycles: ', jpt,  jptmax, nb_cycles 
    1819 
    1920; legend line text 
     
    2425IF strpos(txt_format, 'U') NE -1 THEN leg_txt = leg_txt+'('+field.units+') ' 
    2526IF strpos(txt_format, 'B') NE -1 THEN leg_txt = leg_txt+legz+' ' 
     27 
     28CASE plttyp OF  
     29   'yfx': leg_txt = 'Linfit = '+string(coeff(1)) 
     30   ELSE: 
     31END   
    2632 
    2733 
     
    8894; case pltt plt1d 
    8995IF debug_w THEN print,  'size(time) ',  size(time) 
     96IF debug_w THEN print,  'minc/maxc =', minc, maxc 
     97 
    9098CASE plttyp OF  
    9199   'pltt': BEGIN  
     
    126134      ENDELSE 
    127135   END  
     136   'yfx': BEGIN 
     137      x_leg_1 = -1.e10 
     138      x_leg_2 = -1.e10 
     139      IF debug_w THEN print,  'minc2/maxc2 =', minc2, maxc2 
     140      xmin = minc2 
     141      x_dim = maxc2-minc2 
     142      IF strmid(leg_pos, 1, 1) EQ 'L' THEN BEGIN ; (L)eft 
     143         x_leg_t = xmin+px_tl*x_dim 
     144      ENDIF ELSE BEGIN          ; (R)ight 
     145         x_leg_t = xmin+px_tr*x_dim 
     146      ENDELSE  
     147   END  
    128148ENDCASE  
    129149 
     
    149169      res = execute(pltcmd) 
    150170   END  
     171   ELSE: 
    151172ENDCASE  
    152173IF debug_w THEN print, overc_l 
Note: See TracChangeset for help on using the changeset viewer.