Re: netCDF Creation problem

From: Dennis Shea <shea_at_nyahnyahspammersnyahnyah>
Date: Tue, 18 Jul 2006 12:19:24 -0600 (MDT)

   fName = "stream.trunc.grid."+fyr+".nc"
   system("/bin/rm -f "+fName ) ; remove if exists
   fout = addfile(fName,"c")
   
>Date: Tue, 18 Jul 2006 11:46:42 -0600
>From: Hee-Jeong Baek <Hee-Jeong.Baek_at_noaa.gov>
>Subject: Re: netCDF Creation problem
>To: Dennis Shea <shea_at_cgd.ucar.edu>
>MIME-version: 1.0
>Content-transfer-encoding: 7BIT
>User-Agent: Thunderbird 1.5.0.4 (Windows/20060516)
>X-Virus-Scanned: amavisd-new at ucar.edu
>
>
>1) fatal:Could not create (stream.trunc.grid.1978.nc)
> warning:FileSetFileOption: invalid file or format
> fatal:Execute: Error occurred at or near line 64 in file test.ncl
>
>2) NCAR Command Language Version 4.2.0.a033
>
>thank you!
>
>Hee-Jeong,
>
>
>Dennis Shea wrote:
>> Hello,
>>
>> When asking about an error message, it certainly
>> helps to include what that message was.
>>
>> 1] What was the error message?
>> 2] what version of NCL are you using?
>>
>>
>>
>>> I tried to create netCDF file as same procedure in Application example
>>> of NCL homepage as follows.
>>> But I had error message and I don't know the reason.
>>> output file is stream function and its dimension is (time,lat,lon).
>>> Thank you for help in advance!
>>> Sincerely!
>>> Hee-Jeong
>>>
>>> ;************************************************
>>> ; outfile = stream function
>>> ;************************************************
>>> fout = addfile("stream.trunc.grid."+fyr+".nc","c")
>>> setfileoption(fout,"DefineMode",True)
>>> fileAtt = True
>>> fileAtt_at_creation_date = systemfunc("date")
>>> fileattdef(fout,fileAtt)
>>> dimNames = (/"time","lat","lon"/)
>>> dimSizes = (/nt,nlat,nlon/)
>>> dimUnlim = (/False,False, False/)
>>> filedimdef(fout,dimNames,dimSizes,dimUnlim)
>>> filevarattdef(fout,"sf",sf)
>>> filevardef (fout,"time",typeof(time),getvardims(time))
>>> filevardef (fout,"lat" ,typeof(lat) ,getvardims(lat))
>>> filevardef (fout,"lon" ,typeof(lon) ,getvardims(lon))
>>> filevardef (fout,"sf" ,typeof(sf) ,getvardims(sf))
>>> fout->time = (/time/)
>>> fout->lat = (/lat/)
>>> fout->lon = (/lon/)
>>> fout->sf = (/sf/)
>>>
>>>
>>> _______________________________________________
>>> ncl-talk mailing list
>>> ncl-talk_at_ucar.edu
>>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>>
>>
>>

_______________________________________________
ncl-talk mailing list
ncl-talk_at_ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Jul 18 2006 - 12:19:24 MDT

This archive was generated by hypermail 2.2.0 : Wed Jul 19 2006 - 08:40:45 MDT