<div dir="ltr"><div><div><div><div>Hi NCLers (sorry if multiply posted, I am having trouble with my registration)<br><br></div>I am trying to plot of map of
GOES IR Brightness temperature, but am getting a flat field. When I
print the data they're fine, the values are correct.<br><br></div>The file I am using I created with <br>ncrcat<br></div>to
put all of the 15 minutes GOES netcdf images into a daily file. Maybe I
erred here, maybe something wrong with the time dimension.<br><br></div>Here is ncdump -h of the file I want to plot<br><div>-------------------------------------------------------------------------------<br>ncdump -h <a href="http://test.nc" target="_blank">test.nc</a><br>netcdf test {<br>dimensions:<br> yc = 221 ;<br> xc = 141 ;<br> time = UNLIMITED ; // (130 currently)<br>variables:<br> float new_temp(time, yc, xc) ;<br> new_temp:time = 1372896900 ;<br> new_temp:units = "K" ;<br> new_temp:coordinates = "lon lat" ;<br> new_temp:type = "GVAR" ;<br> new_temp:long_name = "Temperature" ;<br> float new_lat(time, yc, xc) ;<br> new_lat:units = "degrees_north" ;<br> new_lat:long_name = "lat" ;<br> float new_lon(time, yc, xc) ;<br> new_lon:units = "degrees_east" ;<br> new_lon:long_name = "lon" ;<br> int time(time) ;<br> time:units = "seconds since 2013-185 00:15" ;<br><br>// global attributes:<br> :history = "Mon Oct 6 18:26:36 2014: ncrcat <a href="http://goes13_4_2013_185_0015_subset.nc" target="_blank">goes13_4_2013_185_0015_subset.nc</a> ............<br><a href="http://goes13_4_2013_185_2345_subset.nc" target="_blank">goes13_4_2013_185_2345_subset.nc</a> <a href="http://test.nc" target="_blank">test.nc</a>\n",<br> "Mon Oct 6 18:24:58 2014: ncatted -O -a units,time,c,c,seconds since 2013-185 00:15 <a href="http://out.nc" target="_blank">out.nc</a>\n",<br> "Mon Oct 6 18:24:58 2014: ncap2 -O -v -s time=array(0,0,$time) <a href="http://out.nc" target="_blank">out.nc</a>\n",<br> "Mon Oct 6 18:24:58 2014: ncrename -O -d record,time <a href="http://out.nc" target="_blank">out.nc</a>" ;<br> :nco_openmp_thread_number = 1 ;<br>}<br>----------------------------------------------------------------------------------------------------------------------<br></div><div><br>Here is the map plotting code<br></div><div>-----------------------------------------------------------------------------------------------------------------------<br>load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"<br>load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl"<br>load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl"<br><br>;*********************************<br>; read variable<br>;*********************************<br><br>f = addfile("<a href="http://test.nc" target="_blank">test.nc</a>","r")<br>d = f->new_temp ; float data(time, yc, xc) ;<br> ; data:type = "IR" ;<br> printVarSummary(d)<br>;*********************************<br>; Fix the variable so it has recognizable missing data<br>;*********************************<br> new_lat = f->new_lat<br> new_lon = f->new_lon<br><br>;*********************************<br>; create plot<br>;*********************************<br> pltType = "pdf" ; "ps", "eps", "pdf", "png"<br> pltDir = "./"<br><br> wks = gsn_open_wks(pltType, "test")<br> gsn_define_colormap(wks,"BlAqGrYeOrReVi200"); choose a color map<br><br> res = True<br> res@cnFillOn = True ; turn on color<br> res@cnFillMode = "RasterFill" ; cell mode<br> res@cnLinesOn = False ; Turn off contour lines<br> res@gsnSpreadColors = True ; use full colormap<br> res@gsnAddCyclic = False ; data not cyclic<br> res@gsnMaximize = True ; ps, pdf, pdf<br> res@pmTickMarkDisplayMode = "Always" ; use NCL default<br> res@lbLabelAutoStride = True ; let NCL decide spacing<br> res@mpMinLatF = 23.0 ; ; region to zoom in on<br> res@mpMaxLatF = 33.00 ; <br> res@mpMinLonF = -115.200 ; <br> res@mpMaxLonF = -102.20 ; <br> res@mpFillOn = False<br> res@mpOutlineBoundarySets = "National" ; turn on country boundaries<br> res@trGridType = "TriangularMesh" ; Necessary b/c lat, lon<br> res@lbLabelStride = 5.0 ; every other label bar label<br><br> plot = gsn_csm_contour_map_ce(wks,d(111,:,:), res)<br>----------------------------------------------------------------------------------------------------<br><br></div><div>Also, I am getting these warnings,<br></div><div><br>0)
check_for_y_lat_coord: Warning: Data either does not contain a valid
latitude coordinate array or doesn't contain one at all.<br>(0) A valid latitude coordinate array should have a 'units' attribute equal to one of the following values: <br>(0)
'degrees_north' 'degrees-north' 'degree_north' 'degrees north'
'degrees_N' 'Degrees_north' 'degree_N' 'degreeN' 'degreesN' 'deg north'<br>(0)
check_for_lon_coord: Warning: Data either does not contain a valid
longitude coordinate array or doesn't contain one at all.<br>(0) A valid longitude coordinate array should have a 'units' attribute equal to one of the following values: <br>(0)
'degrees_east' 'degrees-east' 'degree_east' 'degrees east'
'degrees_E' 'Degrees_east' 'degree_E' 'degreeE' 'degreesE' 'deg east'<br><br></div><div>Any ideas?<br><br>thanks in advance,<br></div>Dave</div>