New index function Diurnal temperature range above threshold

Issue #15 new
Lars Bärring created an issue

New index function for calculation of number of occurrences of diurnal temperature range above threshold:

Add the following entry to the index_function sheet:

index_function ready parameters description
count_diurnal_temperature_range_occurrences threshold: quantity, condition: operator Calculates the number of times the diurnal temperature range (dtr) meets some condition. This index function takes two inputs, low_data and high_data, i.e. daily minimum and maximum temperature. From this the dtr is first calculated, then the number of occurrences is counted when dtr meets the condition.

Comments (6)

  1. Klaus Zimmermann

    This sounds very reasonable. However, in combination with #13, I wonder if it would be a good idea to have a count reducer instead? Then this function could be performed by the other, normal dtr function, but it might also have implications for completely different counting indices. What do you think?

  2. Lars Bärring reporter

    Very interesting thought. I guess that one could view the implications in different ways.

    • A count reducer for DTR allows the current (soon) dtr index function to do the job. I.e. writing a new reducer instead of a new index function to close this issue.
    • Could this reducer be general enough to perform all other ‘simple’ count indices? Probably yes. Let us think about this and where this might end up. This propably becomes more clear once we begin to formalise the concept of index function in terms of CF mechanisms.

  3. Log in to comment