timeSeries (version 3022.101.2)

orderStatistics: order Statistics

Description

Computes order statistic of a 'timeSeries'.

Usage

orderStatistics(x)

Arguments

x
an univariate 'timeSeries' object.

Value

Function orderStatistics returns the order statistic of an univariate 'timeSeries' object. The output is an object of class 'list'.

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 DataCamp Workspace