Dear all<div>I try to draw cloud mixing ratio for wrf but I got the error message like this</div><div><br></div><div><div>(0) wrf_contour: Warning: illegal setting for ContourParameters attribute</div><div>(0) wrf_contour: Warning: illegal setting for ContourParameters attribute</div>
<div>This is my scripts please help</div><div><br></div><div><br></div><div><div><br></div><div><div><br></div><div>; Example script to produce plots for a WRF real-data run,</div><div>; with the ARW coordinate dynamics option.</div>
<div><br></div><div>load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"</div><div>load "$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRFUserARW.ncl"</div><div>;load "./WRFUserARW.ncl"</div><div>
<br></div><div>begin</div><div>;</div><div>; The WRF ARW input file.</div><div>; This needs to have a ".nc" appended, so just do it.</div><div> ;a = addfile("wrfout_d03_2006-05-06_13:00:<a href="http://00.nc">00.nc</a>","r")</div>
<div><br></div><div> a = addfile("../GEM_09_15/wrfout_d01_2007-06-10_18:00:<a href="http://00.nc">00.nc</a>","r")</div><div><br></div><div>; We generate plots, but what kind do we prefer?</div><div>; type = "x11"</div>
<div>; type = "pdf"</div><div> type = "ps"</div><div>; type = "ncgm"</div><div> wks = gsn_open_wks(type,"QCLOUD-GEM_1018Z")</div><div><br></div><div> setvalues NhlGetWorkspaceObjectId()</div>
<div> "wsMaximumSize" : 33554432</div><div> end setvalues</div><div><br></div><div>; Set some Basic Plot options</div><div> res = True</div><div> res@MainTitle = "REAL-TIME WRF"</div>
<div><br></div><div> pltres = True</div><div> mpres = True</div><div> map = wrf_map(wks,a,mpres)</div><div><div>; What times and how many time steps are in the data set?</div><div> times = wrf_user_list_times(a) ; get times in the file</div>
<div> ntimes = dimsizes(times) ; number of times in the file</div><div><br></div><div>;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;</div><div><br></div><div> res@TimeLabel = times(0) ; Set Valid time to use on plots</div>
<div><br></div><div>;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;</div><div><br></div><div> opts = res</div><div> opts@cnFillOn = True</div><div> gsn_define_colormap(wks,"colors") ; choose a colormap</div>
<div> opts@ContourParameters = (/0,0.1,0.2,0.4,0.6,0.8/)</div><div> ; opts@cnFillOn = True</div><div> opts@cnFillColors = (/"White","Grey","Blue","Green","Yellow","Red"/) ; choose a colormap</div>
<div> ; opts@ContourParameters = (/ 0.2,0.4,0.6,0.8,1/)</div><div> opts@lbBoxLinesOn = False</div><div> res@cnLabelBarEndStyle = "IncludeMinMaxLabels" ; turn on end labels</div><div><br></div>
<div> gsn_define_colormap(wks,"colors") ; choose a colormap</div><div> pressure = 850. ; 500 hPa</div><div>ntimes = 2</div><div>do it = 0, ntimes-1</div><div> ; TERRAIN</div><div> p = wrf_user_getvar(a,"pressure",it)</div>
<div> ter = wrf_user_getvar(a,"QCLOUD",it)</div><div> tc_plane = wrf_user_intrp3d(ter, p,"h",pressure,0.,False)</div><div>; tc_plane = ter(0,:,:)</div><div> tc_plane = tc_plane*1000</div>
<div> tc_plane@units = "g/kg"</div><div> contour = wrf_contour(a,wks,tc_plane,opts)</div><div> ; wrf_map_overlay(wks, map,(/contour/),True)</div><div> plot = wrf_map_overlays(a,wks,(/contour/),pltres,mpres)</div>
<div> end do</div><div><br></div><div>end</div></div></div></div></div>