[gradsusr] How to create a new Grads file?

Celso Bandeira de Melo Ribeiro celso.bandeira at ufjf.edu.br
Fri Nov 15 14:14:01 EST 2013


Hi Andrew,
Good afternoon.
Thank you very much for your attention again.
I will try to do how you suggest.
Best wishes.
Celso


On Fri, 15 Nov 2013 10:10:28 -0800, Andrew Friedman
<andfried at berkeley.edu>
wrote:
> Hi Celso,
> 
> For save.gs, you also have to download the dependency scripts
> parsestr.gsf, parseopt.gsf, qdims.gsf and put them in your GrADS script
> folder.
> The program should work for gridded data, and create a .ctl control file
> and .dat data file. You can open them by using the command ‘open’ on the
> control file.
> 
> One issue I’ve had with save.gs recently is that the line OPTIONS _cal
> causes problems in the control file, so try commenting it out.
> 
> Alternatively, you could use the GrADS command sdfwrite to create a
netcdf
> file.
> 
> If your data aren’t gridded, you may want to try writing as ASCII
> following the instructions in the User’s Guide.
> 
> Andrew
> 
> 
> On Nov 14, 2013, at 1:24 PM, Celso Bandeira de Melo Ribeiro
> <celso.bandeira at ufjf.edu.br> wrote:
> 
>> Hello Andrew,
>> Thank you for your help.
>> I opened the script but I didn't understand how can I use it in may
case.
>> Could you help me more?
>> Thank you again.
>> Best wishes.
>> Celso
>> 
>> 
>> On Tue, 12 Nov 2013 17:01:07 -0800, Andrew Friedman
>> <andfried at berkeley.edu>
>> wrote:
>>> Hi Celso,
>>> 
>>> Check out save.gs by Bin Guan.
>>> 
>>> http://www.atmos.umd.edu/~bguan/grads/GrADS_Scripts.html#save.gs
>>> 
>>> Andrew
>>> 
>>> On Nov 12, 2013, at 4:01 PM, Celso Bandeira de Melo Ribeiro
>>> <celso.bandeira at ufjf.edu.br> wrote:
>>> 
>>>> Dear Grads user,
>>>> I need a help.
>>>> I'm trying to generate monthly rainfall files by accumulating daily
>>>> rainfall from TRMM-MERGE.
>>>> I created an scripts in this Grads and it is adding precipitation
well
>>>> for
>>>> each month, but don't know how can I save this result, the monthly
sum
>>>> in a
>>>> new Grads file.
>>>> Could someone help me to save the monthly rainfall data in a new
Grads
>>>> file?
>>>> Here the code I'm using in Grads.
>>>> 
>>>> 'open pcp.ctl'
>>>> 'jan = sum(prec,t=1,t=31)'
>>>> 'fev = sum(prec,t=32,t=59)'
>>>> 'mar = sum(prec,t=60,t=90)'
>>>> 'abr = sum(prec,t=91,t=120)'
>>>> 'mai = sum(prec,t=121,t=151)'
>>>> 'jun = sum(prec,t=152,t=181)'
>>>> 'jul = sum(prec,t=182,t=212)'
>>>> 'ago = sum(prec,t=213,t=243)'
>>>> 'sep = sum(prec,t=244,t=273)'
>>>> 'oct = sum(prec,t=274,t=304)'
>>>> 'nov = sum(prec,t=305,t=334)'
>>>> 'dec = sum(prec,t=335,t=365)'
>>>> 'd jan'
>>>> 
>>>> I would like to save each monthly file: jan, fev, mar,...,dec.
>>>> 
>>>> Best,
>>>> Celso
>>>> 
>>>> 
>>>> -- 
>>>> ____________________________________________
>>>> Prof. Celso Bandeira de Melo Ribeiro
>>>> Universidade Federal de Juiz de Fora - UFJF
>>>> Faculdade de Engenharia, Plataforma 4
>>>> Departamento de Engenharia Ambiental e Sanitaria
>>>> Bairro Martelos, Juiz de Fora (MG) CEP. 36036-900
>>>> tel. (32) 2102-3400
>>>> Visiting Scholar in Texas A&M University
>>>> _______________________________________________
>>>> gradsusr mailing list
>>>> gradsusr at gradsusr.org
>>>> http://gradsusr.org/mailman/listinfo/gradsusr
>>> 
>>> 
>>> _______________________________________________
>>> gradsusr mailing list
>>> gradsusr at gradsusr.org
>>> http://gradsusr.org/mailman/listinfo/gradsusr
>> 
>> -- 
>> ____________________________________________
>> Prof. Celso Bandeira de Melo Ribeiro
>> Universidade Federal de Juiz de Fora - UFJF
>> Faculdade de Engenharia, Plataforma 4
>> Departamento de Engenharia Ambiental e Sanitaria
>> Bairro Martelos, Juiz de Fora (MG) CEP. 36036-900
>> tel. (32) 2102-3400
>> Visiting Scholar in Texas A&M University
>> _______________________________________________
>> gradsusr mailing list
>> gradsusr at gradsusr.org
>> http://gradsusr.org/mailman/listinfo/gradsusr
> 
> 
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr

-- 
____________________________________________
Prof. Celso Bandeira de Melo Ribeiro
Universidade Federal de Juiz de Fora - UFJF
Faculdade de Engenharia, Plataforma 4
Departamento de Engenharia Ambiental e Sanitaria
Bairro Martelos, Juiz de Fora (MG) CEP. 36036-900
tel. (32) 2102-3400
Visiting Scholar in Texas A&M University


More information about the gradsusr mailing list