[gradsusr] Monthly mean from 16-days interval data for one year

Rafanoharana Serge Claudio rafanoharana at gmail.com
Tue Jun 21 06:31:40 EDT 2011


Forget to mention that I've also tried:

sed -e 's/time = 0, 0, 1, 4, 15, 27, 53, 113, 129, 145, 161, 177, 193, 209,
225, 241, 257, 273, 289, 305, 321, 337, 353 ;/time =  1, 17, 33, 49, 65, 81,
97, 113, 129, 145, 161, 177, 193, 209, 225, 241, 257, 273, 289, 305, 321,
337, 353 ;/g' test.cdl > test1.cdl

but not succeded. The result shows:
.......
.......
Time = 353 ;
.......
.......

Serge



2011/6/21 Rafanoharana Serge Claudio <rafanoharana at gmail.com>

> Hi again,
>
> Any idea about my problem? Anyway, I faced another issue when I "cdo" my
> data.
> Since my data is 16-days time interval during one year, I used:
>
> cdo -r mergetime 1.nc 17.nc 33.nc 49.nc 65.nc 81.nc...321.nc 337.nc 353.nc
> result.nc
>
> Then, when I open the file, I obtain the message:
>
> ga-> sdfopen result.nc
> Scanning self-describing file:  result.nc
> gadsdf: Time unit has too small an increment (min. 1 minute).
>
> The result of "ncdump result.nc"
>  .......
>  .......
>  time = 0, 0, 1, 4, 15, 27, 53, 113, 129, 145, 161, 177, 193, 209, 225,
> 241, 257, 273, 289, 305, 321, 337, 353 ;
>  .......
>  .......
>
> Then I tried to convert the time using sed and ncgen:
>
> sed -e 's/time = 0, 0, 1, 4, 15, 27, 53, 113, 129, 145, 161, 177, 193, 209,
> 225, 241, 257, 273, 289, 305, 321, 337, 353 ;/time =  1, 2, 3, 4, 5, 6, 7,
> 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23 ;/g' test.cdl >
> test1.cdl
>
> ncgen -o result_corrected.nc test1.cdl
>
>
> And the result of ncdump result_corrected.nc gives:
>
>  .......
>  .......
>  time = 353 ;
>  .......
>  .......
>
> instead of 1, 2, 3 ..., 23.
>
> Then I go back again to my first question in order to obtain the monthly
> mean (My previous post).
>
> Any suggestion would be very helpful.
>
> Best regards,
>
> Serge
>
>
>
> 2011/6/21 Rafanoharana Serge Claudio <rafanoharana at gmail.com>
>
>> Dear all,
>>
>> I would like to ask on how to obtain the monthly mean from 16-days
>> interval data within one year.
>>
>> From daily data, I can easily get it using:
>>
>> cdo -r mergetime 1.nc 2.nc 3.nc ..... 366.nc result.nc
>> cdo -r monmean result.nc final.nc
>>
>> but from 16-days interval, I have 23 files and even if I merge them, I
>> will end with TSize =23
>>
>> Any idea will be very helpful.
>>
>> Regards,
>>
>> --
>> Serge
>>
>
>
>
> --
> Serge
>



-- 
Serge
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20110621/d66d6ee9/attachment-0003.html 


More information about the gradsusr mailing list