Project

General

Profile

Extreme temperature indices

Added by DEEPAK PRAJAPAT about 6 years ago

I want to calculate cold nights and such other indices. I have daily gridded minimum temperature data for 1951-2005 period. The reference period daily minimum data to calculate tnn10file.nc is for 30years 1971-2000.To calculate "eca_tn10p" I use-

cdo eca_tn10p tnfile tnn10file outfile

but it gives following error-

"cdo eca_tn10p (Abort): Input streams have different number of time steps!"

I think the tnn10file is creating this error.but I have used the ouputs from all operators "ydaypctl,ydrunpctl,timpctl,runpctl" but all giving similar error.
how to calculate this indice or the tnn10file correctly?

I am using following cdo version-

$ cdo -V
Climate Data Operators version 1.9.3 (http://mpimet.mpg.de/cdo)
Compiled: by Deepak on DESKTOP-C9877AF (x86_64-unknown-cygwin) Apr 7 2018 15:43:06
CXX Compiler: g++ -g -O2 -fopenmp
CXX version : g++ (GCC) 6.4.0
C Compiler: gcc -g -O2 -fopenmp
C version : gcc (GCC) 6.4.0
F77 Compiler: gfortran -g -O2
F77 version : GNU Fortran (GCC) 6.4.0
Features: 7GB C++14 Fortran DATA PTHREADS OpenMP45 HDF5 NC4/HDF5 OPeNDAP SSE2
Libraries: HDF5/1.8.20
Filetypes: srv ext ieg grb1 nc1 nc2 nc4 nc4c nc5
CDI library version : 1.9.3 of Apr 7 2018 15:38:35
CGRIBEX library version : 1.9.0 of Jan 22 2018 09:24:03
NetCDF library version : 4.6.1 of Mar 20 2018 20:24:22 $
HDF5 library version : 1.8.20
EXSE library version : 1.4.0 of Apr 7 2018 15:38:08
FILE library version : 1.8.3 of Apr 7 2018 15:37:56


Replies (3)

RE: Extreme temperature indices - Added by Karin Meier-Fleischer about 6 years ago

Hi Deepak,

without your data it is hard to say what is going wrong. Is your tnfile a time serie? How did you create the tnn10file?

-Karin

RE: Extreme temperature indices - Added by DEEPAK PRAJAPAT about 6 years ago

Similar errer occur when I try on extreme wet days indice. Here I have attached data file (raj19612005_mm_R_invert.nc) and 99th percentile file (R99p_raj19612005.nc).
The 99th percentile file is calculated by "timpctl,99" operator.

RE: Extreme temperature indices - Added by Karin Meier-Fleischer about 6 years ago

Hi Deepak,

please, read the ECA documentation carefully and have a look at your data.

Synopsis

eca tn10p infile1 infile2 outfile

Description

Let infile1 be a time serie of the daily minimum temperature TN, and
infile2 be the 10th percentile TNn10 of daily minimum temperatures
for any period used as reference. Then the percentage of time where
TN < TNn10 is calculated. TNn10 is calculated as the 10th percentile of
daily minimum temperatures of a five day window centred on each calendar
day of a given climate reference period. Note that both TN and TNn10 have
to be given in the same units. The date information of a timestep in
outfile is the date of the last contributing timestep in infile1.

[[https://code.mpimet.mpg.de/projects/cdo/embedded/cdo_eca.pdf]]


Your raj19612005_mm_R_invert.nc file isn't a time serie:

ncdump -h raj19612005_mm_R_invert.nc

netcdf raj19612005_mm_R_invert {
dimensions:
        time = UNLIMITED ; // (16436 currently)
        lon = 19 ;
        lat = 16 ;
variables:
        double time(time) ;
                time:standard_name = "time" ;
                time:long_name = "time" ;
                time:units = "days since 1970-01-01 00:00:00" ;
                time:calendar = "standard" ;
                time:axis = "T" ;
        double lon(lon) ;
                lon:standard_name = "longitude" ;
                lon:long_name = "lon" ;
                lon:units = "degrees_east" ;
                lon:axis = "X" ;
        double lat(lat) ;
                lat:standard_name = "latitude" ;
                lat:long_name = "lat" ;
                lat:units = "degrees_north" ;
                lat:axis = "Y" ;
        float pr(time, lat, lon) ;
                pr:long_name = "precipitation" ;
                pr:units = "kg m-2 s-1" ;
                pr:_FillValue = -3.4e+38f ;
                pr:missing_value = -3.4e+38f ;
                pr:min = 6.04360474425886e-13, 2.24692729700049e-11, 7.0299460697143e-12,
                         3.96110453948495e-06, 1.43311584821504e-08, 0.000145349462400191,
                         4.17992251922072e-10, 1.70436924236128e-05, 9.59270232692155e-11,
                         2.58391555689741e-05, 0.000705478712916374, ...

ncdump -h R99p_raj19612005.nc

netcdf R99p_raj19612005 {
dimensions:
        time = UNLIMITED ; // (1 currently)
        bnds = 2 ;
        lon = 19 ;
        lat = 16 ;
variables:
        double time(time) ;
                time:standard_name = "time" ;
                time:long_name = "time" ;
                time:bounds = "time_bnds" ;
                time:units = "days since 1970-01-01 00:00:00" ;
                time:calendar = "standard" ;
                time:axis = "T" ;
        double time_bnds(time, bnds) ;
        double lon(lon) ;
                lon:standard_name = "longitude" ;
                lon:long_name = "lon" ;
                lon:units = "degrees_east" ;
                lon:axis = "X" ;
        double lat(lat) ;
                lat:standard_name = "latitude" ;
                lat:long_name = "lat" ;
                lat:units = "degrees_north" ;
                lat:axis = "Y" ;
        float pr(time, lat, lon) ;
                pr:long_name = "precipitation" ;
                pr:units = "kg m-2 s-1" ;
                pr:_FillValue = -3.4e+38f ;
                pr:missing_value = -3.4e+38f ;
                pr:min = 6.04360474425886e-13, 2.24692729700049e-11, 7.0299460697143e-12, 
                         3.96110453948495e-06, 1.43311584821504e-08, 0.000145349462400191,
                         4.17992251922072e-10, 1.70436924236128e-05, 9.59270232692155e-11, 
                         2.58391555689741e-05, 0.000705478712916374, 0.00155393220484257,
                         8.85928136407088e-11, 2.42079387135011e-13, 2.34858139880334e-13, 
                         2.2695556642794e-13, 2.36414647624208e-13, 2.34535264473368e-13,
                         2.32870282302136e-13, 5.4316273701005e-12, ...

By the way, if you compute the files yourself try to avoid putting large data arrays in a variable attribute (pr:min).

-Karin

    (1-3/3)