H2ExtGaussian3FParam-class | R Documentation |
CalibrationParam for the H2-extendible Gaussian copula with Exponential margin model for the (average) default counting process with 3 parameter. Extends H2ExCalibrationParam and related to ExtGaussian2FParam.
## S4 method for signature 'H2ExtGaussian3FParam' initialize( .Object, composition = c(2L, 3L), lambda = 0.1, nu = c(0.2, 0.3), rho = NULL, tau = NULL ) ## S4 method for signature 'H2ExtGaussian3FParam' simulate_dt(object, ..., n_sim = 10000L) ## S4 method for signature 'H2ExtGaussian3FParam' expected_pcds_equation( object, times, discount_factors, recovery_rate, coupon, upfront, ..., method = c("default", "prob", "mc") ) ## S4 method for signature 'H2ExtGaussian3FParam' show(object)
.Object |
An object: see the “Initialize Methods” section. |
composition |
An integerish vector with the composition. |
lambda |
Marginal intensity. |
nu |
(Internal) Outer and inner bivariate dependence parameter. |
rho |
Outer and inner bivariate Spearman's Rho. |
tau |
Outer and inner bivariate Kendall's Tau. |
object |
A CalibrationParam-object. |
... |
arguments to specify properties of the new object, to
be passed to |
n_sim |
Number of samples. |
times |
A non-negative numeric vector of timepoints. |
discount_factors |
Non-negative numeric vector for the discount factors for the timepoints. |
recovery_rate |
Non-negative number between zero and one for the recovery rate.. |
coupon |
Numeric number for the running coupon. |
upfront |
Numeric number for the upfront payment. |
method |
Calculation method (either |
The model is defined by the assumption that the multivariate default times τ = (τ_1,
…, τ_d) are from a H2-extendible Gaussian copula model with Exponential margins.
The model is specified by three parameters (in addition to the composition): The marginal rate
lambda
and the (internal) outer and inner dependency parameters nu
(Pearson correlation).
The dependence parameter nu
should not be set by the user; instead they should provide either
rho
(Spearman's Rho) or tau
(Kendall's Tau).
The parameters rho
or tau
should be between zero and one, of length 2, and non-decreasing;
the first value represents the outer dependence between components of different partition
elements and the second value represents the inner depenence between components of the same
partition element.
The link between Spearman's Rho or Kendall's Tau and the
internal dependence parameter (Pearson correlation) is
ρ = 2 \sin(ρ_S \cdot π / 6) and ρ_S = 6 / π \cdot \arcsin(ρ/2)
ρ = \sin(τ \cdot π / 2) and τ = 2 / π \cdot \arcsin(ρ)
For details on the underlying extendible model, see ExtGaussian2FParam.
initialize(H2ExtGaussian3FParam)
: Constructor
simulate_dt(H2ExtGaussian3FParam)
: simulates the vector of default times and returns a matrix x
with
dim(x) == c(n_sim, getDimension(object))
.
expected_pcds_equation(H2ExtGaussian3FParam)
: calculates the payoff equation for a portfolio CDS (vectorized w.r.t.
the argumentes recovery_rate
, coupon
, and upfront
).
show(H2ExtGaussian3FParam)
: Display the object.
lambda
A non-negative number for the marginal rate.
nu
A numeric vector of length 2 for the model specific dependence parameters (global and
component specific; range depends on specific model). Use rho
or tau
in the constructor to
set dependence parameter.
The default times are sampled in a two-stage procedure: First a sample is drawn from the Gaussian
copula whose correlation matrix reflect the inner- and outer-dependency parameters, i.e.
ρ_{i j} = ν_1 if i,j are from different elements of the partition and
ρ_{i j} = ν_2 if i j are from the same element of the partition; then the
results are transformed using stats::qexp()
.
The expected portfolio CDS loss for recovery rate R is calculated using that
\mathbb{E}[g(L_t)] = (1 - R) \cdot F(t)
with g(x) = (1 - R) \cdot x and F being the Exponential distribution function for rate λ.
H2ExtGaussian3FParam() H2ExtGaussian3FParam(composition = c(2L, 4L, 2L), lambda = 8e-2, rho = c(3e-1, 5e-1)) H2ExtGaussian3FParam(composition = c(2L, 4L, 2L), lambda = 8e-2, tau = c(3e-1, 5e-1)) parm <- H2ExtGaussian3FParam(composition = c(2L, 4L, 2L), lambda = 8e-2, rho = c(2e-1, 7e-1)) simulate_dt(parm, n_sim = 5L) parm <- H2ExtGaussian3FParam(c(3, 3, 4, 5), 8e-2, rho = c(3e-1, 6e-1)) expected_pcds_equation( parm, times = seq(25e-2, 5, by = 25e-2), discount_factors = rep(1, 20L), recovery_rate = 0.4, coupon = 1e-1, upfront = 0) expected_pcds_equation( parm, times = seq(25e-2, 5, by = 25e-2), discount_factors = rep(1, 20L), recovery_rate = 0.4, coupon = 1e-1, upfront = 0, method = "mc", n_sim = 1e1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.