fldcor and timcor in CDO
Added by Gohar Ali about 12 years ago
Dear all
I am trying to find correlation between two data sets using CDO. Each file contain one time step of mean JJAS precipitation data. I have used the following commands to calculate their required correlations.
cdo fldcor cru_ppt_JJAS_2002.nc precis_ppt_JJAS_2002.nc fldcor_2002.nc
cdo timcor cru_ppt_JJAS_2002.nc precis_ppt_JJAS_2002.nc timcor_2002.nc
When I open the output files (fldcor_2002.nc, timcor_2002.nc) in grads and display the variables, I get the error message;
"Cannot contour grid - all undefined values"
File query in Grads gives the following message;
ga-> q file
File 1 : CRU TS3.20 Precipitation
Descriptor: timcor_2002.nc
Binary: timcor_2002.nc
Type = Gridded
Xsize = 124 Ysize = 93 Zsize = 1 Tsize = 1 Esize = 1
Number of Variables = 1
pre 0 t,y,x precipitation
Any help in this regards will be highly appreciated.
Best regards.
Gohar
Replies (1)
RE: fldcor and timcor in CDO - Added by Jaison-Thomas Ambadan about 12 years ago
Hi,
I think the problem is, for some reason CDO cannot handle the missing/_FillValue in the input files properly (see, "ncdump -h": _FillValue on both files). If you set the missing value, then you will get a correlation value but I haven't checked if it is the right correlation value.
e.g.
cdo output -fldcor -setmissval,-9e33 cru_ppt_JJAS_2002.nc -setmissval,-9e33 precis_ppt_JJAS_2002.nc
Cheers,
J