Modifications to scoring and graphics production for the final version of code for the C-LAMP paper in GCB.
1 ;************************************************
3 ;************************************************
4 load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
5 load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl"
6 load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl"
7 ;************************************************
9 ;---------------------------------------------------
12 c = addfile("amazon_mask_1x1.nc","c")
17 ;************************************************
19 ;************************************************
21 diri = "/fis/cgd/cseg/people/jeff/clamp_data/observed/biomass/"
23 t = asciiread(diri+fili,(/180,360/),"integer")
27 print (min(t)+"/"+max(t))
29 lon = new((/nlon/),float)
30 lat = new((/nlat/),float)
32 ; data is (89.5N->89.5S) (-179.5->179.5)
35 ; lon = fspan(-179.5,179.5,nlon)
36 ; lat = fspan( -89.5, 89.5,nlat)
39 lon(i) = -179.5 + i*(360./nlon)
43 ; lat(j) = -89.5 + j*(180./nlat)
44 lat(j) = 89.5 - j*(180./nlat)
49 ;=============================
50 ; create lat and long coordinate variables
51 ;============================
54 lon@units = "degrees-east"
59 lat@units = "degrees_north"
61 ;=============================
62 ; name dimensions of t and assign coordinate variables
63 ;============================
68 t@long_name = "amazon mask"
77 ;************************************************
79 ;************************************************
81 wks = gsn_open_wks("ps","xy") ; open a ps file
82 gsn_define_colormap(wks,"gui_default") ; choose colormap
84 res = True ; Use plot options
85 res@cnFillOn = True ; Turn on color fill
86 res@gsnSpreadColors = True ; use full colormap
87 ; res@cnFillMode = "RasterFill" ; Turn on raster color
88 ; res@lbLabelAutoStride = True
89 res@cnLinesOn = False ; Turn off contourn lines
90 res@mpFillOn = False ; Turn off map fill
91 res@gsnAddCyclic = False
92 res@tiMainString = "LC15_amazon_biomass"
94 res@mpMinLatF = -21.1 ; range to zoom in on
96 res@mpMinLonF = 277.28
97 res@mpMaxLonF = 326.43
99 res@gsnSpreadColors = True ; use full colormap
100 res@cnLevelSelectionMode = "ManualLevels" ; Manual contour invtervals
101 ; res@cnMinLevelValF = 1. ; Min level
102 ; res@cnMaxLevelValF = 11. ; Max level
103 ; res@cnLevelSpacingF = 1. ; interval
104 res@cnMinLevelValF = 0. ; Min level
105 res@cnMaxLevelValF = 1. ; Max level
106 res@cnLevelSpacingF = 0.1 ; interval
107 ; pres = True ; panel plot mods desired
108 ; pres@gsnMaximize = True ; fill the page
110 plot = gsn_csm_contour_map_ce(wks,t,res) ; for observed