Yes. It works. Thanks, Dennis.
why it is need to set Raster mode for 2x5 data, but no need for 1x1? is
there any criterion?
On Wed, Feb 20, 2013 at 10:51 AM, Dennis Shea <shea@ucar.edu> wrote:
> When you plot this grid,
>
> res@cnFillMode = "RasterFill" ; Raster Mode
>
> This may help
>
>
> On 2/20/13 8:44 AM, cheryl Ma wrote:
>
>> Hi all,
>>
>> I am regridding a nc file data (data.nc) in 1x1 to a new data nc file (
>> regrid_data.nc) in 2x5. It seems the ncl script I used below works fine
>> (no
>> error information etc.). But plots (attached) created by using these two
>> files look different. Could anyone tell me what is wrong?
>>
>> I have uploaded the files data.nc and regrid_data.nc to the ftp site
>> under
>> incoming.
>> Thanks,
>> Xiaoyan
>>
>> ==============================**============
>> begin
>> f = addfile ("data.nc", "r")
>> var0=f->Deep_Blue_Aerosol_**Optical_Depth_550_Land_QA_Mean
>> printVarSummary(var0)
>> printVarSummary(var0)
>> ;create a sequence for the new values of lat
>> newlat=fspan(-85.0,85.0,85)
>> ;create a sequence for the new values of lon
>> newlon=fspan(-180.0,180.0,72)
>> newlat@units = "degrees_north"
>> newlon@units = "degrees_east"
>> var=linint2(var0&lon,var0&lat,**var0,True,newlon,newlat,0)
>> var!0 = "LAT"
>> var!1 = "LON"
>> var&LAT = newlat
>> var&LON = newlon
>> printVarSummary(var)
>> fout=addfile("regrid_data.nc",**"c")
>> fout@title="Regrid_85*72"
>> fout->var=var
>> end
>>
>>
>>
>> ______________________________**_________________
>> ncl-talk mailing list
>> List instructions, subscriber options, unsubscribe:
>> http://mailman.ucar.edu/**mailman/listinfo/ncl-talk<http://mailman.ucar.edu/mailman/listinfo/ncl-talk>
>>
>>
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Wed Feb 20 09:12:55 2013
This archive was generated by hypermail 2.1.8 : Thu Feb 21 2013 - 11:26:43 MST