Output txt specific format
Ranyére Nóbrega
ranyere.nobrega at SIPAM.GOV.BR
Tue Feb 12 06:24:02 EST 2008
Thanks Stegert.
I'm having a problem with script.
I do not have much knowledge with scripts in Grads, because of this Iask
more its help again.
What would be the variable dlon and dlat that you defined?
Once again, thanks.
>
>
>
>
> Stegert write:
>> Dear Ranyere,
>>
>> I'd suggest doing a loop including the expected
>> spatial and temporal range:
>>
>> ix = 1
>> iy = 1
>> it = 1
>> *or wherever you like to start
>>
>> while (it <= itmax)
>> * where i*max has to be declared above
>> 'set t 'it
>> while (iy <= iymax)
>> 'set y 'iy
>> while (ix <= ixmax)
>> 'set x 'ix
>> ilon = _ilonmin + ix*_dlon
>> ilat = _ilatmin + ix*_dlat
>> * _ilonmin and _dlon (and corresponding lats)
>> * are those declared in your CTL
>> 'd var'
>> * where var is your valiable
>> var2 = subwrd(result,4)
>> output = ilat' 'ilon' 'it' 'var2
>> res = write('output.txt',output,append)
>> ix = ix + 1
>> endwhile
>> iy = iy + 1
>> endwhile
>> it = it + 1
>> endwhile
>> st1 = close('output.txt')
>>
>> Ranyére Nóbrega schrieb:
>>> All, I need generate a output file .txt of the following form:
>>>
>>> LAT LON T VARIABLE
>>>
>>> Can anybody help? Thanks
>>>
>>>
>>> --
>>> __________________________________________________________
>>> Ranyére Silva Nóbrega
>>>
>>
>> --
>> Christoph Stegert: Ecological Modelling group
>> Institut für Meereskunde - Universität Hamburg, Germany
>> Zentrum f. Marine u. Atmosphärische Wissenschaften ZMAW
>> Bundesstr.53, 20146 Hamburg - Phone: +49-40/ 42838-7486
>>
>
>
--
__________________________________________________________
Ranyére Silva Nóbrega
Analista Intelectual
Divisão de Meteorologia e Climatologia - SIPAM
Centro Técnico e Operacional de Porto Velho
More information about the gradsusr
mailing list