[gradsusr] "Time" variable.

Ryglicki, Dr. David david.ryglicki at nrlmry.navy.mil
Thu May 4 17:09:03 EDT 2017


Jeff, Bill –

 

I see. The “long way” it is. Thanks for your help.

 

~Dave

 

From: gradsusr-bounces at gradsusr.org [mailto:gradsusr-bounces at gradsusr.org] On Behalf Of Jeff Duda
Sent: Thursday, May 4, 2017 1:49 PM
To: GrADS Users Forum
Subject: Re: [gradsusr] "Time" variable.

 

Dave,

Since "time" is a string, I don't think you would want to display it as a field anyway. Bill's suggestion is the correct way to go.

Jeff Duda

 

On Thu, May 4, 2017 at 3:29 PM, Ryglicki, Dr. David <david.ryglicki at nrlmry.navy.mil> wrote:

Hi everyone.

 

Quick question about a reserved variable in GrADS. According to the scripting doc page (http://cola.gmu.edu/grads/gadoc/script.html), there are four predefined variables: lat, lon, lev, and time. However, I can’t get “time” to work.

 

After opening control file (which I know works!)…

 

ga-> set x 1

LON set to 0 0

ga-> set y 1

LAT set to -90 -90

ga-> d lat

Result value = -90

ga-> d lon

Result value = 0

ga-> d time

Syntax Error:  Invalid Operand

  'time' not a variable or function name

  Error ocurred at column 1

DISPLAY error:  Invalid expression

  Expression = time

ga-> d lev

Result value = 1

ga-> set t 1 last

Time values set: 2008:8:6:0 2008:8:9:23

ga-> d time

Syntax Error:  Invalid Operand

  'time' not a variable or function name

  Error ocurred at column 1

DISPLAY error:  Invalid expression

  Expression = time

 

Did I mess this up? Is this a bug? Deprecated feature? The destination of this information is a time series text file via fprintf.gs. I realize I could do this the “long way” with an iterator and repeated ‘q time’ calls, but I was wondering if there’s a shortcut. Thanks.

 

~Dave


_______________________________________________
gradsusr mailing list
gradsusr at gradsusr.org
http://gradsusr.org/mailman/listinfo/gradsusr




-- 

Jeff Duda
Post-doctoral research fellow
University of Oklahoma School of Meteorology

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20170504/9527f0a1/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5386 bytes
Desc: not available
Url : http://gradsusr.org/pipermail/gradsusr/attachments/20170504/9527f0a1/attachment.bin 


More information about the gradsusr mailing list