Project

General

Profile

[bug report] CDO trend does NOT take into account the spacing on the X axis.

Added by Adriano Fantini almost 5 years ago

This is a bug report. Please let me know if I should put this somewhere else.

The operator -trend does not take into account of the spacing between timesteps.

EXAMPLE:

If we have a monthly file from 1900 to 2000 the trend operator will work correctly. However, if one selects only one season (e.g. -selseas,MAM) and then calculates the trend on that, the resulting trend is 4 times higher than it should be, because the spacing between timesteps is not linear in the selected file. The spacing is:
1, 2, 3, 13, 14, 15, 25, 26, 27... etc
M, A, M, M, A, M, M, A, M... etc

but -trend assumes it is:
1, 2, 3, 4, 5, 6, 7, 8, 9... etc


    (1-2/2)