Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

statistics-colSums

Column Statistics


Description

A collection and description of functions to compute column statistical properties of financial and economic time series data.

The functions are:

colStats calculates column statistics,
colSums calculates column sums,
colMeans calculates column means,
colSds calculates column standard deviations,
colVars calculates column variances,
colSkewness calculates column skewness,
colKurtosis calculates column kurtosis,
colMaxs calculates maximum values in each column,
colMins calculates minimum values in each column,
colProds computes product of all values in each column,
colQuantiles computes quantiles of each column.

Usage

colStats(x, FUN, ...) 

colSds(x, ...)
colVars(x, ...)
colSkewness(x, ...)
colKurtosis(x, ...)
colMaxs(x, ...)
colMins(x, ...)
colProds(x, ...)
colQuantiles(x, prob = 0.05, ...)

colStdevs(x, ...)
colAvgs(x,  ...)

Arguments

FUN

a function name. The statistical function to be applied.

prob

a numeric value, the probability with value in [0,1].

x

a rectangular object which can be transformed into a matrix by the function as.matrix.

...

arguments to be passed.

Value

the functions return a numeric vector of the statistics.

See Also

link{rowStats}.

Examples

## Simulated Return Data in Matrix Form -
   x = matrix(rnorm(252), ncol = 2)
     
## Mean Columnwise Statistics -
   colStats(x, FUN = mean)
   
## Quantiles Column by Column -
   colQuantiles(x, prob = 0.10, type = 1)

timeSeries

Financial Time Series Objects (Rmetrics)

v3062.100
GPL (>= 2)
Authors
Diethelm Wuertz [aut] (original code), Tobias Setz [cre], Yohan Chalabi [ctb], Martin Maechler [ctb] (<https://orcid.org/0000-0002-8685-9910>)
Initial release
2020-01-24

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.