Computes the diversification probability distribution and the effective number of bets of an allocation.
Arguments
- b
A vector of exposures (allocations).
- sigma
A
n x n
covariance matrix.- t
A
n x n
torsion matrix.
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)
#> $p
#> [,1]
#> [1,] 0.1886652
#> [2,] 0.2822564
#> [3,] 0.2262331
#> [4,] 0.3028453
#>
#> $enb
#> [1] 3.934066
#>