QuantLib: TCopulaPolicy Class Reference

A free/open-source library for quantitative finance Reference manual - version 1.20

Classes | Public Member Functions | List of all members
TCopulaPolicy Class Reference

Student-T Latent Model's copula policy. More...

`#include <ql/experimental/math/tcopulapolicy.hpp>`

## Classes
struct | initTraits

## Public Member Functions
| TCopulaPolicy (const std::vector< std::vector< Real > > &factorWeights=std::vector< std::vector< Real > >(), const initTraits &vals=initTraits())
Size | numFactors () const
| Number of independent random factors.
initTraits | getInitTraits () const
| returns a copy of the initialization arguments
const std::vector< Real > & | varianceFactors () const
Probability | cumulativeY (Real val, Size iVariable) const
Probability | cumulativeZ (Real z) const
| Cumulative probability of the idiosyncratic factors (all the same)
Probability | density (const std::vector< Real > &m) const
Real | inverseCumulativeY (Probability p, Size iVariable) const
Real | inverseCumulativeZ (Probability p) const
Real | inverseCumulativeDensity (Probability p, Size iFactor) const
Disposable< std::vector< Real > > | allFactorCumulInverter (const std::vector< Real > &probs) const

## Detailed Description

Student-T Latent Model's copula policy.

Describes the copula of a set of normalized Student-T independent random factors to be fed into the latent variable model. The latent model requires the independent variables to be of unit variance so the policy expects the factors coefficients to be as usual and the T variables to be normalized, the normalization is performed by the policy. To normalize the random variables they are divided by the square root of the variance of each T ( \( \frac{\nu}{\nu-2}\))

Examples
  BasketLosses.cpp.

## Constructor & Destructor Documentation

## ◆ TCopulaPolicy()

TCopulaPolicy | ( | const std::vector< std::vector< Real > > & | factorWeights = `std::vector< std::vector< Real > >()`,
|  | const initTraits & | vals = `initTraits()`
| ) |  |
| explicit

Delayed initialization of the distribution parameters and caches. To be called by the latent model.

## Member Function Documentation

## ◆ cumulativeY()

Probability cumulativeY | ( | Real | val,
|  | Size | iVariable
| ) |  | const

Cumulative probability of a given latent variable. The iVariable parameter is the index of the requested variable.

## ◆ density()

Probability density | ( | const std::vector< Real > & | m | ) | const

Probability density of a given realization of values of the systemic factors (remember they are independent). Intended to be used in numerical integration of an arbitrary function depending on those values.

## ◆ inverseCumulativeY()

Real inverseCumulativeY | ( | Probability | p,
|  | Size | iVariable
| ) |  | const

Returns the inverse of the cumulative distribution of the (modelled) latent variable (as indexed by iVariable). Involves the convolution of the factors' distributions.

## ◆ inverseCumulativeZ()

Real inverseCumulativeZ | ( | Probability | p | ) | const

Returns the inverse of the cumulative distribution of the idiosincratic factor. The LM here is limited to all idiosincratic factors following the same distribution.

## ◆ inverseCumulativeDensity()

Real inverseCumulativeDensity | ( | Probability | p,
|  | Size | iFactor
| ) |  | const

Returns the inverse of the cumulative distribution of the systemic factor iFactor.