[gradsusr] if else statement

Manoranjan LPAS lpasmanoranjan at gmail.com
Thu Jul 2 05:31:13 EDT 2015


Dear Ryan,
Thank you very much for your suggestion. But this could not solve my
problem. Because, at some times (e. g. at t 101) there is no data.
e.g. If I display the variable by setting lat 5 , lon 80 and time 1 to
100, it is fine.
But at t 101, it is giving error.
Again from t 102 to 250, it is fine... Like this.

Kind regards
Sridhara

On Thursday, July 2, 2015, Ryan Hickman <ryan at allisonhouse.com
<javascript:_e(%7B%7D,'cvml','ryan at allisonhouse.com');>> wrote:

> Mano,
>
> Use 'set undef 99999' instead of looping over every grid point
> (inefficient.)
>
> - Ryan
>
> > On Jul 1, 2015, at 9:44 PM, Manoranjan LPAS <lpasmanoranjan at gmail.com>
> wrote:
> >
> > Dear users,
> > I was trying to save the grads output values at a grid point in ACSII
> format. I found that there are some missing values at many times. So I
> wanted to write those missing values as 99999. When I used the following, I
> am getting every values 99999.
> >
> >  'd 'var''
> > if (subwrd(result,3) > -99999)
> > val=subwrd(result,3)
> > else
> > val=99999
> > endif
> > rc=write(outfile.txt,val)
> >
> > Can anybody help me where am I doing mistake.
> >
> > Thanking You,
> > Kind Regards
> > Mano
> > _______________________________________________
> > 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
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20150702/e21f9472/attachment-0001.html 


More information about the gradsusr mailing list