<div dir="ltr">i am facing problem using grads. i tried to display the result but everytime i display it in a different time it gives me a different picture too. can somebody help me solve this problem. my grads was set offline.<div>
<br></div><div>dieni</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/9/5 <span dir="ltr"><<a href="mailto:gradsusr-request@gradsusr.org" target="_blank">gradsusr-request@gradsusr.org</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Send gradsusr mailing list submissions to<br>
<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>
<br>
To subscribe or unsubscribe via the World Wide Web, visit<br>
<a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
or, via email, send a message with subject or body 'help' to<br>
<a href="mailto:gradsusr-request@gradsusr.org">gradsusr-request@gradsusr.org</a><br>
<br>
You can reach the person managing the list at<br>
<a href="mailto:gradsusr-owner@gradsusr.org">gradsusr-owner@gradsusr.org</a><br>
<br>
When replying, please edit your Subject line so it is more specific<br>
than "Re: Contents of gradsusr digest..."<br>
<br>
<br>
Today's Topics:<br>
<br>
1. Re: lterp+sdfwrite adding extra longitude values<br>
(Charles Seman - NOAA Federal)<br>
2. Re: Decadal average plot (Hosmay Lopez)<br>
3. Problems reading a netcdf file (Matt Bunkers - WFO UNR)<br>
4. Re: how to merge file data using grads<br>
(Muhammad Yunus Ahmad Mazuki)<br>
5. Re: Problems reading a netcdf file (Jeff Duda)<br>
<br>
<br>
----------------------------------------------------------------------<br>
<br>
Message: 1<br>
Date: Wed, 04 Sep 2013 18:02:48 -0400<br>
From: Charles Seman - NOAA Federal <<a href="mailto:charles.seman@noaa.gov">charles.seman@noaa.gov</a>><br>
Subject: Re: [gradsusr] lterp+sdfwrite adding extra longitude values<br>
To: GrADS Users Forum <<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>><br>
Message-ID: <<a href="mailto:5227AE08.8000305@noaa.gov">5227AE08.8000305@noaa.gov</a>><br>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed<br>
<br>
Andrew,<br>
<br>
from <a href="http://grads.iges.org/grads/gadoc/gradfunclterp.html" target="_blank">http://grads.iges.org/grads/gadoc/gradfunclterp.html</a>:<br>
---<br>
"If the domain of source is larger than the domain of dest, the returned<br>
result will have an expanded grid to cover the requested domain."<br>
---<br>
<br>
compare the longitude limits for the fine and coarse grids... it could<br>
be that if the specified fine grid limits are outside the coarse<br>
longitude grid limits, the interpolation puts data in two extra outer<br>
longitudes in the destination grid to satisfy the grid environment<br>
defined by "set X 1 [number of longitude points in <a href="http://fine.nc" target="_blank">fine.nc</a>]"... so try<br>
"set dfile 2 ; set X 1 [number of longitude points in <a href="http://coarse.nc" target="_blank">coarse.nc</a>]" after<br>
"sdfopen <a href="http://coarse.nc" target="_blank">coarse.nc</a>"... this would set the global longitude limits to<br>
those of <a href="http://coarse.nc" target="_blank">coarse.nc</a>, which would then be within the limits of <a href="http://fine.nc" target="_blank">fine.nc</a><br>
<br>
Hope this helps,<br>
Chuck<br>
<br>
On 09/04/2013 04:42 PM, Andrew Friedman wrote:<br>
> Hi GrADS users,<br>
><br>
> I am using lterp to regrid a file to a coarser resolution, and saving the variable to netcdf using sdfwrite.<br>
><br>
> My problem is that the output file has 2 additional longitudes compared to the input grid destination description file.<br>
><br>
> Similar to the example in the lterp documentation in the grads index:<br>
><br>
> sdfopen <a href="http://fine.nc" target="_blank">fine.nc</a><br>
> set X 1 [number of longitude points in <a href="http://fine.nc" target="_blank">fine.nc</a>]<br>
> sdfopen <a href="http://coarse.nc" target="_blank">coarse.nc</a><br>
> output = lterp(fine,coarse.2,aave)<br>
> set sdfwrite <a href="http://output.nc" target="_blank">output.nc</a><br>
> sdfwrite output<br>
><br>
> I've had this issue before when there is just one input file, and explicitly defining longitude with the step 'set X 1 [number of longitude points]' works to solve it. In this case however, I'm not sure how to limit the longitude dimension of the output.<br>
> Do you have ideas how I can fix this?<br>
><br>
> Thanks,<br>
> Andrew<br>
><br>
><br>
> ------<br>
> Andrew Friedman<br>
> Graduate Student, UC Berkeley Geography<br>
> <a href="mailto:andfried@berkeley.edu">andfried@berkeley.edu</a><br>
><br>
><br>
><br>
><br>
> _______________________________________________<br>
> gradsusr mailing list<br>
> <a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>
> <a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
><br>
<br>
--<br>
<br>
Please note that <a href="mailto:Charles.Seman@noaa.gov">Charles.Seman@noaa.gov</a> should be considered my NOAA<br>
email address, not <a href="mailto:cjs@gfdl.noaa.gov">cjs@gfdl.noaa.gov</a>.<br>
<br>
********************************************************************<br>
Charles Seman <a href="mailto:Charles.Seman@noaa.gov">Charles.Seman@noaa.gov</a><br>
U.S. Department of Commerce / NOAA / OAR<br>
Geophysical Fluid Dynamics Laboratory voice: (609) 452-6547<br>
201 Forrestal Road fax: (609) 987-5063<br>
Princeton, NJ 08540-6649 <a href="http://www.gfdl.noaa.gov/~cjs/" target="_blank">http://www.gfdl.noaa.gov/~cjs/</a><br>
********************************************************************<br>
<br>
"The contents of this message are mine personally and do not reflect any<br>
official or unofficial position of the United States Federal Government,<br>
the United States Department of Commerce, or NOAA."<br>
<br>
<br>
------------------------------<br>
<br>
Message: 2<br>
Date: Wed, 4 Sep 2013 22:57:18 +0000<br>
From: Hosmay Lopez <<a href="mailto:hlopez@rsmas.miami.edu">hlopez@rsmas.miami.edu</a>><br>
Subject: Re: [gradsusr] Decadal average plot<br>
To: GrADS Users Forum <<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>><br>
Message-ID:<br>
<<a href="mailto:8A902EB84795C94C8726F11DC8C574A81D456F9E@EXCHANGE1.amazon.rsmas.miami.edu">8A902EB84795C94C8726F11DC8C574A81D456F9E@EXCHANGE1.amazon.rsmas.miami.edu</a>><br>
<br>
Content-Type: text/plain; charset="iso-8859-1"<br>
<br>
OK, I see,<br>
<br>
You can make use of while loops and output the averages, that is one record for each decaded totaling 20 as follows. Your averages will be output by the fwrite command, you will need a control file to read it.<br>
<br>
***************************************<br>
'set gxout fwrite'<br>
'set fwrite decade_data.dat'<br>
is = 1<br>
while(is < = 2400)<br>
<br>
'set t 'is<br>
'd tloop(ave(temperature, t+0, t+119))'<br>
'c'<br>
<br>
is = is + 120<br>
endwhile<br>
'disable fwrite'<br>
'set gxout contour'<br>
*****************************************<br>
Hosmay Lopez<br>
Rosenstiel School of Marine and Atmospheric Science<br>
University of Miami<br>
4600 Rickenbacker Causeway Miami, FL 33149<br>
Office: MSC337<br>
Phone: (305) 298-8006<br>
________________________________<br>
From: <a href="mailto:gradsusr-bounces@gradsusr.org">gradsusr-bounces@gradsusr.org</a> [<a href="mailto:gradsusr-bounces@gradsusr.org">gradsusr-bounces@gradsusr.org</a>] on behalf of Mubashar Ahmad [<a href="mailto:mubashardogar@gmail.com">mubashardogar@gmail.com</a>]<br>
Sent: Wednesday, September 04, 2013 5:18 PM<br>
To: GrADS Users Forum<br>
Subject: Re: [gradsusr] Decadal average plot<br>
<br>
<br>
Hi lopez,<br>
<br>
Thanks for your input but I don't want runing mean average based on 10 years, instead I want decadal average such that after getting averaged value for first 10 years (average of 1 to 120 months) it should give value for next 10 years (average of 121 to 240th time) and so on.<br>
<br>
Thanks,<br>
<br>
Mubashar<br>
<br>
On Sep 4, 2013 9:45 PM, "Hosmay Lopez" <<a href="mailto:hlopez@rsmas.miami.edu">hlopez@rsmas.miami.edu</a><mailto:<a href="mailto:hlopez@rsmas.miami.edu">hlopez@rsmas.miami.edu</a>>> wrote:<br>
Dear Mubashar,<br>
<br>
You can use the tloop function in conjunction with the ave function as follows:<br>
<br>
set t 61 2340<br>
d tloop(ave(temperature,t-60,t+60))<br>
<br>
This will create an average for decadal timescales.<br>
Note, the time start at month 61 = beginning of year 6 and ends at month 2340 = 5 years prior to year 200 of your data.<br>
<br>
At the end you should have a monthly time series of decadal averaged quantity.<br>
<br>
Best,<br>
<br>
Hosmay Lopez<br>
Rosenstiel School of Marine and Atmospheric Science<br>
University of Miami<br>
4600 Rickenbacker Causeway Miami, FL 33149<br>
Office: MSC337<br>
Phone: (305) 298-8006<br>
<br>
________________________________________<br>
From: <a href="mailto:gradsusr-bounces@gradsusr.org">gradsusr-bounces@gradsusr.org</a><mailto:<a href="mailto:gradsusr-bounces@gradsusr.org">gradsusr-bounces@gradsusr.org</a>> [<a href="mailto:gradsusr-bounces@gradsusr.org">gradsusr-bounces@gradsusr.org</a><mailto:<a href="mailto:gradsusr-bounces@gradsusr.org">gradsusr-bounces@gradsusr.org</a>>] on behalf of Mubashar Ahmad [<a href="mailto:mubashardogar@gmail.com">mubashardogar@gmail.com</a><mailto:<a href="mailto:mubashardogar@gmail.com">mubashardogar@gmail.com</a>>]<br>
Sent: Wednesday, September 04, 2013 2:12 PM<br>
To: gradsusr<br>
Subject: [gradsusr] Decadal average plot<br>
<br>
Dear Grads Users,<br>
<br>
I have monthly time series data (let say surface temperature) and<br>
wanted to plot it on decadal average basis. I mean first value of plot<br>
will be average of first 120 months and the next value of my plot will<br>
be average of next 120 months and so on. In total for 200 years I<br>
should get 20 value in plot. How can I do that? Y axis will be decadal<br>
average temperature values and x axis can be labelled 1, 2, 3 up 20<br>
instead of months or years.<br>
<br>
Thanks,<br>
<br>
Mubashar<br>
_______________________________________________<br>
gradsusr mailing list<br>
<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><mailto:<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>><br>
<a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
<br>
_______________________________________________<br>
gradsusr mailing list<br>
<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><mailto:<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>><br>
<a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <a href="http://gradsusr.org/pipermail/gradsusr/attachments/20130904/f8a95e3e/attachment-0001.html" target="_blank">http://gradsusr.org/pipermail/gradsusr/attachments/20130904/f8a95e3e/attachment-0001.html</a><br>
<br>
------------------------------<br>
<br>
Message: 3<br>
Date: Wed, 4 Sep 2013 17:53:42 -0600<br>
From: Matt Bunkers - WFO UNR <<a href="mailto:matthew.bunkers@noaa.gov">matthew.bunkers@noaa.gov</a>><br>
Subject: [gradsusr] Problems reading a netcdf file<br>
To: <a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>
Message-ID:<br>
<CAB_myoNDpT_8az_2Z=nW0p0dwudrtK9e9treWy=<a href="mailto:EJ5g2Q8RRBQ@mail.gmail.com">EJ5g2Q8RRBQ@mail.gmail.com</a>><br>
Content-Type: text/plain; charset="utf-8"<br>
<br>
Hi,<br>
<br>
I have a netcdf file that cannot be opened with sdfopen because it doesn't<br>
follow the COORDS convention. After creating a descriptor file with x, y,<br>
and t definitions I can open the file with xdfopen and display data.<br>
However, when I use the "set lat" and "set lon" commands in this scenario<br>
the program bombs out. I therefore decided to create the full descriptor<br>
file (with dtype netcdf, pdef set accordingly, etc.) so I could plot my<br>
area of interest with the "set lat" and "set lon" commands. That all seems<br>
to work fine; however, my data values now are all zero. This is perplexing<br>
because I could see non-zero data when opening the file with the xdfopen<br>
command, but not when I opened the netcdf file with the open command and<br>
full descriptor file (I'm trying to plot forecast precipitation, by the<br>
way). If needed I can provide a copy of my descriptor file. Thanks for<br>
any advice you can offer.<br>
<br>
-- Matt Bunkers, NWS Rapid City, SD<br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <a href="http://gradsusr.org/pipermail/gradsusr/attachments/20130904/9c2503be/attachment-0001.html" target="_blank">http://gradsusr.org/pipermail/gradsusr/attachments/20130904/9c2503be/attachment-0001.html</a><br>
<br>
------------------------------<br>
<br>
Message: 4<br>
Date: Thu, 5 Sep 2013 10:25:17 +0800<br>
From: Muhammad Yunus Ahmad Mazuki <<a href="mailto:ukm.yunus@gmail.com">ukm.yunus@gmail.com</a>><br>
Subject: Re: [gradsusr] how to merge file data using grads<br>
To: GrADS Users Forum <<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>><br>
Message-ID:<br>
<<a href="mailto:CAKJBA6ZJbEeWB-iJC-bLDDHtjkJSFULt%2BA3GmxcsWwt7D%2BXDvA@mail.gmail.com">CAKJBA6ZJbEeWB-iJC-bLDDHtjkJSFULt+A3GmxcsWwt7D+XDvA@mail.gmail.com</a>><br>
Content-Type: text/plain; charset="iso-8859-1"<br>
<br>
You can either use read and write back script in grads. Or you can work<br>
directly on the file with 'cdo'. That if you want to rewrite the files into<br>
one file. You can also use template option in a controller file to read all<br>
10 file as one file.<br>
<br>
<br>
On Wed, Sep 4, 2013 at 3:57 PM, Lyndon Mark Olaguera <<br>
<a href="mailto:olagueralyndonmark429@gmail.com">olagueralyndonmark429@gmail.com</a>> wrote:<br>
<br>
> what type of data file is this? an output from WRF?<br>
> Can you give some details..<br>
><br>
> Lyndon<br>
><br>
> *Lyndon Mark P. Olaguera*<br>
> Assistant Instructor<br>
> Ateneo de Manila University<br>
> 426 6001<br>
> loc 5695<br>
><br>
><br>
> On Wed, Sep 4, 2013 at 2:48 PM, Indah Lutfiyanti <<br>
> <a href="mailto:indahlutfiyanti387@yahoo.com">indahlutfiyanti387@yahoo.com</a>> wrote:<br>
><br>
>> Dear Senior,<br>
>><br>
>> please help me, I have problem how to merge data which is separate 10<br>
>> file to be 1 file using grads?<br>
>><br>
>> thank you<br>
>><br>
>> Lutfi<br>
>><br>
>><br>
>><br>
>> _______________________________________________<br>
>> gradsusr mailing list<br>
>> <a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>
>> <a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
>><br>
>><br>
><br>
> _______________________________________________<br>
> gradsusr mailing list<br>
> <a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>
> <a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
><br>
><br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <a href="http://gradsusr.org/pipermail/gradsusr/attachments/20130905/c6c7ea27/attachment-0001.html" target="_blank">http://gradsusr.org/pipermail/gradsusr/attachments/20130905/c6c7ea27/attachment-0001.html</a><br>
<br>
------------------------------<br>
<br>
Message: 5<br>
Date: Wed, 4 Sep 2013 21:45:53 -0500<br>
From: Jeff Duda <<a href="mailto:jeffduda319@gmail.com">jeffduda319@gmail.com</a>><br>
Subject: Re: [gradsusr] Problems reading a netcdf file<br>
To: GrADS Users Forum <<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>><br>
Message-ID:<br>
<<a href="mailto:CAAig09B51hgYE%2BYH-qJFqyuAGmJKfB3rHotkcuTYwP2GHis0-g@mail.gmail.com">CAAig09B51hgYE+YH-qJFqyuAGmJKfB3rHotkcuTYwP2GHis0-g@mail.gmail.com</a>><br>
Content-Type: text/plain; charset="iso-8859-1"<br>
<br>
Matt,<br>
I would have to guess there is some sort of error in your control file. I<br>
frequently view netCDF files in Grads and have had similar issues in the<br>
past.<br>
<br>
Jeff Duda<br>
<br>
<br>
On Wed, Sep 4, 2013 at 6:53 PM, Matt Bunkers - WFO UNR <<br>
<a href="mailto:matthew.bunkers@noaa.gov">matthew.bunkers@noaa.gov</a>> wrote:<br>
<br>
> Hi,<br>
><br>
> I have a netcdf file that cannot be opened with sdfopen because it doesn't<br>
> follow the COORDS convention. After creating a descriptor file with x, y,<br>
> and t definitions I can open the file with xdfopen and display data.<br>
> However, when I use the "set lat" and "set lon" commands in this scenario<br>
> the program bombs out. I therefore decided to create the full descriptor<br>
> file (with dtype netcdf, pdef set accordingly, etc.) so I could plot my<br>
> area of interest with the "set lat" and "set lon" commands. That all seems<br>
> to work fine; however, my data values now are all zero. This is perplexing<br>
> because I could see non-zero data when opening the file with the xdfopen<br>
> command, but not when I opened the netcdf file with the open command and<br>
> full descriptor file (I'm trying to plot forecast precipitation, by the<br>
> way). If needed I can provide a copy of my descriptor file. Thanks for<br>
> any advice you can offer.<br>
><br>
> -- Matt Bunkers, NWS Rapid City, SD<br>
><br>
> _______________________________________________<br>
> gradsusr mailing list<br>
> <a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>
> <a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
><br>
><br>
<br>
<br>
--<br>
Jeff Duda<br>
Graduate research assistant<br>
University of Oklahoma School of Meteorology<br>
Center for Analysis and Prediction of Storms<br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <a href="http://gradsusr.org/pipermail/gradsusr/attachments/20130904/228d2488/attachment.html" target="_blank">http://gradsusr.org/pipermail/gradsusr/attachments/20130904/228d2488/attachment.html</a><br>
<br>
------------------------------<br>
<br>
_______________________________________________<br>
gradsusr mailing list<br>
<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>
<a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
<br>
<br>
End of gradsusr Digest, Vol 43, Issue 18<br>
****************************************<br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><span style="color:rgb(102,0,0)"><span style="background-color:rgb(255,255,255)"><font><span style="font-family:arial,helvetica,sans-serif"><span><b>Dieni Fitriani Buch<span></span>ary Akman<br>
</b><i><font><font>Laboratory of</font> Meteorology</font><br><span>Major in Applied Meteorology<br>Department of Geophysics and Meteorology<br>Faculty of Mathematics and Natural Science<br>Bogor Agricultural University<br>
<br></span></i></span></span></font></span></span>
</div>