StructuredMoments | R Documentation |
calculates covariance, coskewness and cokurtosis matrices as structured estimators
M2.struct(R, struct = c("Indep", "IndepId", "observedfactor", "CC"), f = NULL)
M3.struct(
R,
struct = c("Indep", "IndepId", "observedfactor", "CC", "latent1factor", "CS"),
f = NULL,
unbiasedMarg = FALSE,
as.mat = TRUE
)
M4.struct(
R,
struct = c("Indep", "IndepId", "observedfactor", "CC"),
f = NULL,
as.mat = TRUE
)
R |
an xts, vector, matrix, data frame, timeSeries or zoo object of asset returns |
struct |
string containing the preferred method. See Details. |
f |
vector or matrix with observations of the factor, to be used with 'observedfactor'. See Details. |
unbiasedMarg |
TRUE/FALSE whether to use a correction to have an unbiased estimator for the marginal skewness values, in case of 'Indep' or 'IndepId', default FALSE |
as.mat |
TRUE/FALSE whether to return the full moment matrix or only the vector with the unique elements (the latter is advised for speed), default TRUE |
The coskewness and cokurtosis matrices are defined as the matrices of dimension p x p^2 and p x p^3 containing the third and fourth order central moments. They are useful for measuring nonlinear dependence between different assets of the portfolio and computing modified VaR and modified ES of a portfolio.
Structured estimation is based on the assumption that the underlying data-generating process is known, or at least resembles the assumption. The first four structured estimators correspond to the models 'independent marginals', 'independent and identical marginals', 'observed multi-factor model' and 'constant correlation'. Coskewness estimation includes an additional model based on the latent 1-factor model proposed in Simaan (1993).
The constant correlation and 1-factor coskewness and cokurtosis matrices can be found in Martellini and Ziemann (2010). If f is a matrix containing multiple factors, then the multi-factor model of Boudt, Lu and Peeters (2915) is used. For information about the other structured matrices, we refer to Boudt, Cornilly and Verdonck (2017)
Dries Cornilly
Boudt, Kris, Wanbo Lu and Benedict Peeters. 2015. Higher order comoments of multifactor models and asset allocation. Finance Research Letters, 13, 225-233.
Boudt, Kris, Brian G. Peterson, and Christophe Croux. 2008. Estimation and Decomposition of Downside Risk for Portfolios with Non-Normal Returns. Journal of Risk. Winter.
Boudt, Kris, Dries Cornilly and Tim Verdonck. 2020 A Coskewness Shrinkage Approach for Estimating the Skewness of Linear Combinations of Random Variables. Journal of Financial Econometrics, 18(1), 1-23.
Ledoit, Olivier and Michael Wolf. 2003. Improved estimation of the covariance matrix of stock returns with an application to portfolio selection. Journal of empirical finance, 10(5), 603-621.
Martellini, Lionel, and Volker Ziemann. 2010. Improved estimates of higher-order comoments and implications for portfolio selection. Review of Financial Studies, 23(4), 1467-1502.
Simaan, Yusif. 1993. Portfolio selection and asset pricing: three-parameter framework. Management Science, 39(5), 68-577.
CoMoments
ShrinkageMoments
EWMAMoments
MCA
NCE
data(edhec)
# structured estimation with constant correlation model
# 'as.mat = F' would speed up calculations in higher dimensions
sigma <- M2.struct(edhec, "CC")
m3 <- M3.struct(edhec, "CC")
m4 <- M4.struct(edhec, "CC")
# compute equal-weighted portfolio modified ES
mu <- colMeans(edhec)
p <- length(mu)
ES(p = 0.95, portfolio_method = "component", weights = rep(1 / p, p), mu = mu,
sigma = sigma, m3 = m3, m4 = m4)
# compare to sample method
sigma <- cov(edhec)
m3 <- M3.MM(edhec)
m4 <- M4.MM(edhec)
ES(p = 0.95, portfolio_method = "component", weights = rep(1 / p, p), mu = mu,
sigma = sigma, m3 = m3, m4 = m4)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.