[ncl-talk] Issues adding variables to chart
BLIUJUS, STEVEN D CTR USAF AFMC AFLCMC/HBAW-OL
steven.bliujus.3.ctr at us.af.mil
Thu May 7 08:13:03 MDT 2015
I am trying to take two files and add the variables together. One variable
has data over water while the other has missing values, when I try adding
the values, nothing prints out for the areas over the ocean. I tried setting
the variables to 0 instead of missing values but that did not work either. I
have attached three images: var1, var2, and var. The variable var is the
addition, and the addition gets done over land but not over water. Not sure
why this is occurring, my only guess is the struggle with missing data.
However, when I look at var, it doesn't look as though it is adding the
variables properly either since the max for var is 2.49807, but the max for
var2 is 2.544, so there is an obvious discrepancy. Here is my info:
1. I am using Version 6.1.2
2. My Script:
load "/home/bliujuss/ncl/lib/ncarg/nclscripts/csm/gsn_code.ncl"
load "/home/bliujuss/ncl/lib/ncarg/nclscripts/wrf/WRFUserARW.ncl"
load "/home/bliujuss/ncl/lib/ncarg/nclscripts/csm/gsn_csm.ncl"
begin
a=addfile("/home/bliujuss/Plots/MYD08_D3.051.timeAverage.1.nc","r")
b=addfile("/home/bliujuss/Plots/MOD08_D3.051.timeAverage.0.nc","r")
wks = gsn_open_wks("x11","plt_aod")
gsn_define_colormap(wks,"3gauss")
var1 = a->Deep_Blue_Aerosol_Optical_Depth_550_Land_QA_Mean(:,:)
var2 = b->Optical_Depth_Land_And_Ocean_Mean(:,:)
printVarSummary(var1)
printMinMax(var1, True)
printVarSummary(var2)
printMinMax(var2, True)
var = var1
var = 0.0
var = var2+var1
printVarSummary(var)
printMinMax(var, True)
pltres = True
pltres at tiMainString = "AOD550"
pltres at cnFillOn = True
pltres at gsnSpreadColors = False
pltres at gsnAddCyclic = False
pltres at cnLineLabelsOn = False
pltres at cnLineLabelBackgroundColor = "white"
;plot = gsn_csm_contour_map_ce(wks,var({-46.2:46.5},{-4.5:184.5}),pltres)
;plot = gsn_csm_contour_map_ce(wks,var1({-46.2:46.5},{-4.5:184.5}),pltres)
;plot = gsn_csm_contour_map_ce(wks,var2({-46.2:46.5},{-4.5:184.5}),pltres)
End
3. Files are attached
4. Images attached
5. No error message
6. gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-44)
Steven Bliujus, Contractor
SEMS/16WS WXE
557th Weather Wing
DNS: 232-7151
-------------- next part --------------
A non-text attachment was scrubbed...
Name: var.PNG
Type: image/png
Size: 98593 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150507/de202950/attachment-0003.png
-------------- next part --------------
A non-text attachment was scrubbed...
Name: var1.PNG
Type: image/png
Size: 103824 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150507/de202950/attachment-0004.png
-------------- next part --------------
A non-text attachment was scrubbed...
Name: var2.PNG
Type: image/png
Size: 116247 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150507/de202950/attachment-0005.png
-------------- next part --------------
A non-text attachment was scrubbed...
Name: MOD08_D3.051.timeAverage.0.nc
Type: application/octet-stream
Size: 73976 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150507/de202950/attachment-0002.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: MYD08_D3.051.timeAverage.1.nc
Type: application/octet-stream
Size: 74156 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150507/de202950/attachment-0003.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5647 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150507/de202950/attachment-0001.bin
More information about the ncl-talk
mailing list