Learn R Programming

SpecsVerification (version 0.4-0)

ClimEns: Construct a climatological ensemble from a vector of observations.

Description

Construct a climatological ensemble from a vector of observations. Optionally, the climatological ensemble observation at time t can be constructed without the observation at time t (leave-one-out).

Usage

ClimEns(obs, leave.one.out=TRUE)

Arguments

obs
vector of length N. The observations.
leave.one.out
boolean, default=TRUE. Whether the n-th observation should be removed from the n-th row of the ensemble matrix.

Value

  • The function returns a matrix with N rows and N-1 columns (if leave.one.out=TRUE) or N columns otherwise. Basically, the observations are repeated N times as rows of a matrix.

Examples

Run this code
# Example:
  obs <- rnorm(10)
  ClimEns(obs)

Run the code above in your browser using DataLab