createClimdex: Create a climdex.pcic::climdexInput from a 'dataclim' object

Description Usage Arguments Details Value Author(s) See Also Examples

Description

This function creates a climdex.pcic::climdexInput object from a dataclim object.

Usage

1
createClimdex(myDataclim, basePeriod)

Arguments

myDataclim

A dataclim object.

basePeriod

A numeric vector containing the years of the base period, e.g. 1961:1990. The basePeriod is used for the computation of the quantile threshold needed for some indices in the climdex.pcic package. If NULL (the default), the basePeriod will be extracted from the respective slot of the dataclim object.

Details

This is a simple wrapper to convert a dataclim object to a climdexInput object.

Note that if basePeriod is not a sequence of consecutive years, the range min(basePeriod):max(basePeriod) will be input to the climdex.pcic computations.

Value

A climdexInput object.

Author(s)

Boris Orlowsky <boris@climate-babel.org>

See Also

climdex.pcic-package

Examples

1
2
3
4
5
data(potsdam)
date <- as.Date(potsdam$date)
myDataclim <- createDataclim(date=date, tmin=potsdam$tmin, tmax=potsdam$tmax,
                          prec=potsdam$prec, basePeriod=1981:2010)
myClimdex <- createClimdex(myDataclim, 1981:2010)

Example output



iki.dataclim documentation built on May 2, 2019, 2:38 a.m.