npp/51.zonavg.ncl
author Forrest Hoffman <forrest@climatemodeling.org>
Mon, 26 Jan 2009 22:08:20 -0500
changeset 0 0c6405ab2ff4
permissions -rw-r--r--
Initial commit of C-LAMP Diagnostics from Jeff Lee
forrest@0
     1
; ***********************************************
forrest@0
     2
; xy_1.ncl
forrest@0
     3
; ***********************************************
forrest@0
     4
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
forrest@0
     5
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl"  
forrest@0
     6
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl"  
forrest@0
     7
;************************************************
forrest@0
     8
begin
forrest@0
     9
;************************************************
forrest@0
    10
; read in data
forrest@0
    11
;************************************************
forrest@0
    12
;f     = addfile ("i01.03cn_1545-1569_ANN_climo.nc","r")
forrest@0
    13
 f     = addfile ("i01.04casa_1605-1629_ANN_climo.nc","r")
forrest@0
    14
 u     = f->NPP 
forrest@0
    15
 v     = zonalAve(u)
forrest@0
    16
forrest@0
    17
 nsec_per_year = 60*60*24*365
forrest@0
    18
forrest@0
    19
 v = v * nsec_per_year
forrest@0
    20
forrest@0
    21
 v@long_name = "NPP (gC/m2/year)"        
forrest@0
    22
;************************************************
forrest@0
    23
; plotting parameters
forrest@0
    24
;************************************************
forrest@0
    25
 wks   = gsn_open_wks ("png","xy")                
forrest@0
    26
forrest@0
    27
 res                  = True                     
forrest@0
    28
;res@tiMainString     = "Model i01.03cn"         
forrest@0
    29
 res@tiMainString     = "Model i01.04casa"         
forrest@0
    30
forrest@0
    31
 plot  = gsn_csm_xy (wks,v&lat,v(0,:),res) 
forrest@0
    32
end