Learn R Programming

distr6 (version 1.3.2)

correlation: Distribution Correlation

Description

Correlation of a distribution.

Usage

correlation(object)

Arguments

object

Distribution.

Value

Either '1' if distribution is univariate or the correlation as a numeric or matrix.

R6 Usage

$correlation()

Details

In terms of covariance, the correlation of a distribution is defined by the equation, $$\rho_{XY} = \sigma_{XY}/\sigma_X\sigma_Y$$ where \(\sigma_{XY}\) is the covariance of X and Y and \(\sigma_X, \sigma_Y\) and the respective standard deviations of X and Y.

If the distribution is univariate then returns \(1\).

Calculates correlation analytically from variance. If an analytic expression for variance isn't available, returns error. To impute a numeric expression, use the CoreStatistics decorator.