[gradsusr] Handling two data files with different time increment

Jennifer Adams jma at cola.iges.org
Fri Feb 15 13:13:23 EST 2013


When you use grid coordinates to access data (e.g. X, Y, Z, T, or E), GrADS converts them internally to world coordinates based on the grid of the default file. So if you 'set dfile 2' before using an expression like 'ave(b.2,t=400,t=500)' it should be okay, but you will have trouble comparing that to b.1(t=40). I suggest creating an intermediate data set that contains hourly averages of your 6-minute data, then comparing that with your hourly data. 
--Jennifer

On Feb 15, 2013, at 10:48 AM, Jonni Lehtiranta wrote:

> Hi!
> 
> I have a problem I'm unable to overcome by myself. I have two files, output from
> the same model. The primary file has many variables once per hour, the secondary
> has one variable (let's call it B) for each timestep. That's 10 times per hour. Like this:
> 
> TDEF 55 LINEAR 00z15FEB2013 1hr
> 
> and
> 
> TDEF 550 LINEAR 00z15FEB2013 6mn
> 
> I want to use these in a script (grads -bpc draw.gs), such that the script opens both in
> this order. I want to loop over the hours, and draw hourly averages of B. Or multiply
> the hourly outputs by this average, stuff like that.
> 
> In direct mode, writing commands to grads by hand,
> 
>  d B.2(t=500)                    works, but
>  d ave(B.2, t=400, t=500)  does not work.
> 
> I can't easily use "time=00z16feb2013" syntax.
> 
> Can I somehow tell grads that I want "t = 400" to mean the steps in the second file?
> 
> 
> Yours sincerely,
> -Jonni Lehtiranta
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr

--
Jennifer M. Adams
IGES/COLA
4041 Powder Mill Road, Suite 302
Calverton, MD 20705
jma at cola.iges.org



-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20130215/77e5bff9/attachment-0003.html 


More information about the gradsusr mailing list