effective_bets {uncorbets} | R Documentation |
Effective Number of Bets
Description
Computes the diversification probability distribution and the effective number of bets of an allocation.
Usage
effective_bets(b, sigma, t)
Arguments
b |
A vector of exposures (allocations). |
sigma |
A |
t |
A |
Value
A list
of length 2 with:
-
p
: the diversification probability distribution; -
enb
: the effective number of bets.
Examples
# extract the invariants from the data
set.seed(123)
log_ret <- matrix(rnorm(400), ncol = 4) / 10
# compute the covariance matrix
sigma <- stats::cov(log_ret)
# torsion
torsion_cov <- torsion(sigma = sigma, model = 'minimum-torsion', method ='exact')
# 1/N reference
b <- rep(1 / ncol(log_ret), ncol(log_ret))
# ENB
effective_bets(b = b, sigma = sigma, t = torsion_cov)
[Package uncorbets version 0.1.2 Index]