Calculating Percentiles in GrADS - please help

Arlindo da Silva dasilva at ALUM.MIT.EDU
Wed Nov 19 01:50:32 EST 2008


On Thu, Nov 13, 2008 at 9:32 AM, ml <Malgorzata.Liszewska at imgw.pl> wrote:

> Dear Arlindo,
>
> I really appreciate your advices on computing percentiles using PyGrads,
> but
> unfortunately I have problems. I tried to follow your approach: installed
> PyGrads and other modules and make examples using your script but I cannot
> export grads variable into Python:
>
> >>> xx=ga.exp('djfslp/100')
> Traceback (most recent call last):
>  File "<stdin>", line 1, in <module>
>  File "/usr/lib/python2.5/site-packages/grads/ganum.py", line 80, in exp
>    return self.expr(expr)
>  File "/usr/lib/python2.5/site-packages/grads/ganum.py", line 380, in expr
>    d = self.eval(expr)
>  File "/usr/lib/python2.5/site-packages/grads/gacore.py", line 668, in eval
>    got = self.Reader.readline()
> KeyboardInterrupt
>
> I haven't used python earlier probably I am doing something wrong ??
> I tried also the example with model.ctl file and ts - the result was
> similar.
>
> any idea what's wrong?
>


Which version of GrADS/PyGrADS are you using? From the error message, it
appears that it is using method "expr" to export the variable, something
that requires grads v2.0.a3 (or a version of v1.9 not yet released.)  If
using v1.9.0-rc1, make sure the IPC extensions are included, read this
http://opengrads.org/wiki/index.php?title=Python_Interface_to_GrADS


>
> I am working on Kubuntu 7.10.
>

This should be OK,

--
Arlindo da Silva
dasilva at alum.mit.edu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20081119/1f3e413c/attachment.html 


More information about the gradsusr mailing list