copulaPdfStudent
First introduced in version 3.00.6
Syntax
copulaPdfStudent(rho, nu, X)
Details
Calculates the probability density of a Student's t copula at the specified evaluation points.
A t copula extends the correlation structure of a Gaussian copula by introducing the degrees-of-freedom parameter nu, allowing it to capture symmetric heavy-tailed dependence in both the upper and lower tails. Smaller degrees of freedom indicate stronger tail dependence. As nu approaches infinity, the t copula numerically converges to the Gaussian copula.
copulaPdfStudent is commonly used for density evaluation in
extreme-risk modeling, such as comparing the likelihood contribution of sample
points under a heavy-tailed model and a Gaussian baseline model.
Parameters
rho is a scalar or matrix that specifies the linear correlation parameters.
- When X is two-dimensional data, rho can be a DOUBLE scalar that
specifies the correlation coefficient between the two variables. The value must
be in the range
(-1, 1). - rho can also be a 2×2 correlation matrix.
nu is an INT or DOUBLE scalar that specifies the degrees-of-freedom parameter
of the t copula. The value must be in the range (0, ∞).
- Smaller nu values indicate heavier tails.
- Larger nu values make the t copula approach the Gaussian copula.
X is a non-empty two-dimensional numeric matrix or table with dimensions n×p (p = 2), specifying the set of evaluation points for which densities are computed. Here, n is the number of evaluation points, that is, the number of rows in X; p is the number of variables, that is, the number of columns in X.
- All elements must be finite numbers.
- Rows whose elements are all in the open interval
(0, 1)are evaluated using the t copula density formula. - Rows with any element u on the boundary of or outside the interval (
u <= 0oru >= 1) return 0. - When X is a table, each column represents a variable, and the column order defines the variable order.
Returns
A DOUBLE vector with the same length as the number of rows in X. The i-th element of the returned vector is the copula probability density for the i-th row of X.
Examples
Example 1. Calculate the probability density of a two-dimensional t copula with
correlation coefficient 0.5 and 5 degrees of freedom at the central point
[0.5, 0.5].
X = matrix([0.5], [0.5])
y = copulaPdfStudent(0.5, 5, X)
y
// Output: [1.2753276779771845]
Example 2. Compare densities for the same set of evaluation points under different degrees of freedom. With fewer degrees of freedom, the model assigns higher densities to joint tail extremes.
u1 = [0.05, 0.5, 0.95]
u2 = [0.05, 0.5, 0.95]
X = matrix(u1, u2)
yNu4 = copulaPdfStudent(0.6, 4, X)
yNu30 = copulaPdfStudent(0.6, 30, X)
yNu4
// Output: [4.439090113641852, 1.4147106052612917, 4.439090113641852]
yNu30
// Output: [3.5554172160824566, 1.2710039953378847, 3.5554172160824566]
Example 3. Generate pseudo-observations with heavy-tailed characteristics using a t copula, and then use the fitted results to calculate densities for these sample points.
X = copulaRandStudent(0.6, 5, 1000)
fitRes = copulaFitStudent(X)
y = copulaPdfStudent(fitRes.rho, fitRes.nu, X)
avg(y)
// Output: 1.7878752240836582 (illustrative value; refer to the actual output)
fitRes.nu
// Output: 6.0093821588887755 (illustrative value; refer to the actual output)
Example 4. Demonstrate how boundary points are handled. The first row contains 0 and the third row contains 1, so the corresponding densities are 0.
u1 = [0.0, 0.2, 0.9]
u2 = [0.1, 0.3, 1.0]
X = matrix(u1, u2)
y = copulaPdfStudent(0.7, 5, X)
y
// Output: [0, 1.7018622176354719, 0]
Related functions: copulaFitStudent, copulaRandStudent, copulaCdfStudent, copulaPdfGaussian, copulaPdfClayton, copulaPdfFrank, copulaPdfGumbel
