Description Usage Arguments Value Author(s) See Also Examples
View source: R/CDVineCopSelect.R
This function fits either a C- or a D-vine copula model to a d-dimensional copula data set.
Appropriate pair-copula families are selected using BiCopSelect
and estimated sequentially.
1 2 | CDVineCopSelect(data, familyset=NA, type, selectioncrit="AIC",
indeptest=FALSE, level=0.05)
|
data |
An N x d data matrix (with uniform margins). |
familyset |
An integer vector of pair-copula families to select from (the independence copula MUST NOT be specified in this vector unless one wants to fit an independence vine!).
The vector has to include at least one pair-copula family that allows for positive and one that allows for negative dependence.
If |
type |
Type of the vine model: |
selectioncrit |
Character indicating the criterion for pair-copula selection. Possible choices: |
indeptest |
Logical; whether a hypothesis test for the independence of |
level |
Numeric; significance level of the independence test (default: |
family |
A d*(d-1)/2 vector of pair-copula families with values |
par |
A d*(d-1)/2 vector of pair-copula parameters. |
par2 |
A d*(d-1)/2 vector of second pair-copula parameters for the t-, BB1, BB6, BB7 and BB8 copulas. |
Eike Brechmann
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | # simulate from a 4-dimensional D-vine copula with mixed pair-copulas
d = 4
dd = d*(d-1)/2
family = c(1,2,3,4,7,3)
par = c(0.5,0.4,2,1.5,1.2,1.5)
par2 = c(0,5,0,0,2,0)
type = 2
simdata = CDVineSim(1000,family,par,par2,type)
# determine appropriate pair-copula families and parameters
# of a D-vine structure
## Not run:
CDVineCopSelect(simdata,type=2,familyset=c(1:10,13,14,23,24))
## End(Not run)
|
The CDVine package is no longer developed actively.
Please consider using the more general VineCopula package
(see https://CRAN.R-project.org/package=VineCopula),
which extends and improves the functionality of CDVine.
$family
[1] 1 2 3 4 7 3
$par
[1] 0.5287534 0.4084750 2.0735836 1.4954025 1.2222256 1.4217389
$par2
[1] 0.000000 4.514544 0.000000 0.000000 1.911842 0.000000
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.