get_logNcorr_bounds: Computation of the ranges of Correlations for Log-Normal...

View source: R/get_logNcorr_bounds.R

get_logNcorr_boundsR Documentation

Computation of the ranges of Correlations for Log-Normal distributions

Description

Correlations between Log-Normal distributed variables should be in specific ranges depending on their CVs. These bounds represent a necessary condition for obtaining a positive definite covariance/correlation matrix for the underlying normal distribution [1].

Usage

get_logNcorr_bounds(mu, sd)

Arguments

mu

Array object which contains mean values of variables with a Log-Normal distribution.

sd

Array object which contains sd values of variables with a Log-Normal distribution.

Details

If X=(x1,...,xN) is a set of variables with a Log-Normal distribution with parameters \theta,\Omega, Y=ln(X) will be a set of Normal parameters with parameters \mu,\Sigma. The bond between X and Y, as well as between the parameters of the two multivariate distribution, is a non-linear transformation. Thus, Log-Normal correlation structure has to fulfill the bound described in [1] in order to obtain a positive definite covariance matrix for the underlying Normal distribution.

Value

A Matrix object with a number of rows equal to the number of Log-Normal variables couples and 4 columns containing:

  • var1: numerical index of the first Log-Normal variable of the couple

  • var2: numerical index of the second Log-Normal variable of the couple

  • lower: lower bound for the range of Log-Normal correlation between var1 and var2

  • upper: upper bound for the range of Log-Normal correlation between var1 and var2.

Author(s)

Alessandro De Carlo alessandro.decarlo01@universitadipavia.it

References

[1] Henrique S. Xavier, Filipe B. Abdalla, Benjamin Joachimi, Improving lognormal models for cosmological fields, Monthly Notices of the Royal Astronomical Society, Volume 459, Issue 4, 11 July 2016, Pages 3693–3710, https://doi.org/10.1093/mnras/stw874

Examples

sd2 <- array(c(1,2,0.5,3)) #array with standard deviations of variables
mu2 <- array(c(3,0.2,1,8)) #array with means of variables
get_logNcorr_bounds(mu2,sd2)

#returns
#      var1 var2   lower     upper
# [1,]    1    2 -0.1506242 0.3025073
# [2,]    1    3 -0.8529277 0.9942674
# [3,]    1    4 -0.8885903 0.9996221
# [4,]    2    3 -0.1275056 0.3517665
# [5,]    2    4 -0.1443341 0.3146269
# [6,]    3    4 -0.8398526 0.9968250



AlessandroDeCarlo27/mvlognCorrEst documentation built on March 23, 2023, 10:11 a.m.