Learn R Programming

timeSeries (version 4041.111)

orderStatistics: Order statistics

Description

Computes the order statistics of a "timeSeries" object.

Usage

orderStatistics(x)

Value

a named list, in which each component is an univariate "timeSeries" containing the order statistics of the corresponding column of the input time series.

Arguments

x

a "timeSeries" object.

Details

orderStatistics computes the order statistics for each column of a "timeSeries" object. The output is a named list with the order statistics for each column in a separate component.

Examples

Run this code
## Load Swiss Pension Fund Benchmark Data -  
   setRmetricsOptions(myFinCenter = "GMT")
   X <- LPP2005REC[, "SPI"]
   colnames(X)
   
## Compute 1% Order Statistics -
   N <- round(0.01*nrow(X))
   N
   OS <- orderStatistics(X)[[1]]
   OS[1:N, ]

Run the code above in your browser using DataLab