This function evaluates the second derivative of a given parametric bivariate copula density with respect to its parameter(s) and/or its arguments.

BiCopDeriv2(
  u1,
  u2,
  family,
  par,
  par2 = 0,
  deriv = "par",
  obj = NULL,
  check.pars = TRUE
)

Arguments

u1, u2

numeric vectors of equal length with values in \([0,1]\).

family

integer; single number or vector of size length(u1); defines the bivariate copula family:
0 = independence copula
1 = Gaussian copula
2 = Student t copula (t-copula)
3 = Clayton copula
4 = Gumbel copula
5 = Frank copula
6 = Joe copula
13 = rotated Clayton copula (180 degrees; survival Clayton'') \cr `14` = rotated Gumbel copula (180 degrees; survival Gumbel'')
16 = rotated Joe copula (180 degrees; ``survival Joe'')
23 = rotated Clayton copula (90 degrees)
`24` = rotated Gumbel copula (90 degrees)
`26` = rotated Joe copula (90 degrees)
`33` = rotated Clayton copula (270 degrees)
`34` = rotated Gumbel copula (270 degrees)
`36` = rotated Joe copula (270 degrees)

par

Copula parameter.

par2

integer; single number or vector of size length(u1); second parameter for the t-Copula; default is par2 = 0, should be an positive integer for the Students's t copula family = 2.

deriv

Derivative argument
"par" = second derivative with respect to the first parameter (default)
"par2" = second derivative with respect to the second parameter (only available for the t-copula)
"u1" = second derivative with respect to the first argument u1
"u2" = second derivative with respect to the second argument u2
"par1par2" = second derivative with respect to the first and second parameter (only available for the t-copula)
"par1u1" = second derivative with respect to the first parameter and the first argument
"par2u1" = second derivative with respect to the second parameter and the first argument (only available for the t-copula)
"par1u2" = second derivative with respect to the first parameter and the second argument
"par2u2" = second derivative with respect to the second parameter and the second argument (only available for the t-copula)

obj

BiCop object containing the family and parameter specification.

check.pars

logical; default is TRUE; if FALSE, checks for family/parameter-consistency are omitted (should only be used with care).

Value

A numeric vector of the second-order bivariate copula derivative

  • of the copula family

  • with parameter(s) par, par2

  • with respect to deriv

  • evaluated at u1 and u2.

Details

If the family and parameter specification is stored in a BiCop() object obj, the alternative version

BiCopDeriv2(u1, u2, obj, deriv = "par")

can be used.

References

Schepsmeier, U. and J. Stoeber (2014). Derivatives and Fisher information of bivariate copulas. Statistical Papers, 55 (2), 525-542.
https://link.springer.com/article/10.1007/s00362-013-0498-x.

Author

Ulf Schepsmeier, Jakob Stoeber

Examples


## simulate from a bivariate Student-t copula
set.seed(123)
cop <- BiCop(family = 2, par = -0.7, par2 = 4)
simdata <- BiCopSim(100, cop)

## second derivative of the Student-t copula w.r.t. the first parameter
u1 <- simdata[,1]
u2 <- simdata[,2]
BiCopDeriv2(u1, u2, cop, deriv = "par")
#>   [1]   5.52809763  -6.76374650 -31.83591292  -7.01735211  12.12433505
#>   [6]  15.34033040   7.73510022  -0.94670323  -1.41601296 -10.02843789
#>  [11]  -8.68029395   0.95588885  -0.43138922   9.42578602  -6.56519892
#>  [16]  -1.92568441  -5.59326067  -7.43485156   8.75046881  -4.39491258
#>  [21]   0.54810296   6.50816869  -6.08440441   8.24368107  -1.88422962
#>  [26]  -6.83775896  -2.49916761  -0.50757932  24.59738707  24.02868314
#>  [31]  -8.20068903  -0.40169484  14.00199683  -7.33235759  14.39322430
#>  [36]   1.62021137   0.20592689  -1.63022993  12.18709188  -6.38424843
#>  [41]  15.64016667   0.52662869  -0.08898609  -2.14329519  18.97063160
#>  [46]  23.47566683  11.93263827  -5.92514078  -8.04998550  12.10185339
#>  [51]   9.66701779  -6.18525476  -7.12666182  -6.03618458  -6.23950226
#>  [56]  43.13666702 -26.40456885  -2.31934111  -5.05991291  11.85207116
#>  [61]  10.63559810  -5.09236098  -5.21402757  -3.46821079  23.50426791
#>  [66]  -6.53208680  -2.60973050   6.55672714  -7.58773112  24.26485948
#>  [71]   6.35521025 -13.51591361  18.47383323  -3.78259121  12.86727622
#>  [76]   9.52164910  -2.02966281  -3.73662609   0.64114966  -2.45665241
#>  [81]   7.97389045  12.63800575  12.57201860   8.05718034  -0.18516031
#>  [86]  -0.54918861  -8.48560057   5.11986176  12.45511274  -0.16930071
#>  [91]  21.40568958   9.99918150  12.22886338  13.95705626  -2.90314950
#>  [96]  -0.70096338 -36.15097718  12.04052543   9.84430985  16.15624508

## estimate a Student-t copula for the simulated data
cop <- BiCopEst(u1, u2, family = 2)
## and evaluate its second derivative w.r.t. the second argument u2
BiCopDeriv2(u1, u2, cop, deriv = "u2")
#>   [1]   -50.9297502   -20.3997269 -9647.0491441    -3.0619298   -19.2131620
#>   [6]   439.0305273   -11.9305604  -981.0602729     6.0432357   -49.2532624
#>  [11]    31.4704288     3.2419182    -4.6891806   -16.3300434     5.5496307
#>  [16]    11.5078191     2.3379621  1415.4822777   -69.4183935     0.4417732
#>  [21]    14.9629162   -13.0874751    11.3172255    -9.4718976   -76.0198858
#>  [26]   288.6360881  -166.1668958   -18.9079400  -151.8387268   -24.3486367
#>  [31]   -43.1482782    -6.4339824   -17.7634868    10.6928234   -21.0956436
#>  [36]    -1.8977339 -1493.6473702   -10.4407591   -23.0412676     4.0813051
#>  [41]   -40.4913757   -21.9430547    40.5151457    22.4774720  -359.9646048
#>  [46]   -51.4848808   -27.6384419     2.4087037  -161.6757427   -18.6545135
#>  [51]   -23.4287291    -0.9156089    -7.9151776    62.7708305    -1.0671406
#>  [56]   -76.9350918 -7856.8717329   -67.1375847     3.5570211   -21.0306386
#>  [61]   -28.1863945     1.7354084   -28.9232194     8.1934421   -74.6844705
#>  [66]     2.8909110    -1.8476828   -15.4994178    12.0408783  3385.9824223
#>  [71]   -10.0727446   269.7842111  -128.6626053     7.0941952   -53.9328817
#>  [76]    -0.8665695    -5.1601313    34.0996573   -20.6058487    -7.7898285
#>  [81]   -17.1704758   -25.2604303   -19.7325242   -59.7799324    -7.9521905
#>  [86]   -30.2167805    19.4505062    -9.3929417   -19.4740699    23.2683910
#>  [91]   -66.4589642   -42.2406065   -18.9331405   -22.8359080     9.5854430
#>  [96]    -1.2060011  2401.2319963   152.7789732   -22.7630506   -18.1517880