climdex.tnnp: Percent of Values Above nth Percentile Daily Minimum...

View source: R/indices.R

climdex.tnnpR Documentation

Percent of Values Above nth Percentile Daily Minimum Temperature

Description

This function computes the climdex index TNnp.

Computation of these values outside of the base period involves comparing the temperature data for each day with the corresponding percentiles for a 5 day running window surrounding that day. The resulting monthly series is then the monthly percentage of values that meet the criteria.

Usage

climdex.tnnp(ci, freq = c("monthly", "annual", "halfyear", "seasonal"),
  quant = 0.9, op = ">")

Arguments

ci

Object of type climdexInput.

freq

Time frequency to aggregate to.

quant

Quantile to used (must be stated and calculated within climdexInput.raw). Default: 0.9

op

Operator to use for comparison. Default: ">"

Details

This function takes a climdexInput object as input and computes the monthly or annual percent of values above the 90th percentile of baseline daily minimum temperature.

Computation of these values inside the base period is more complicated. It involves comparison of the daily temperature data with the corresponding day of temperature data in each of (n - 1) sets of data. The sets consist of the data for the base period with the current year replaced with each of the other years. The results of these comparisons are then averaged to give a value between 0 and 1. Finally, the resulting daily series is aggregated to a monthly series by averaging these daily values and multiplying by 100 to give a monthly percentile value.

Value

A vector containing a timeseries containing values of the index on a monthly or annual timescale.

Note

These functions may calculate slightly different results than fclimdex.

The bootstrapping method is not well defined for cases where the base data contains numerous missing values. Because of that, this code (and fclimdex) are not very robust against missing values with respect to these indicies. When computing percentiles inside the base period, both this implementation and fclimdex do not divide through by the number of non-missing values when aggregating the values inside the base period. Instead, they divide through by the number of base years minus one. This will result in a negative bias when missing values are present.


ECA-D/climind documentation built on Nov. 26, 2022, 10:20 a.m.