Description Usage Arguments Details Value See Also Examples
Evaluates the density of a regular vine model (drvine
) or log density
(logdrvine
).
1 2 3 |
dat |
Data matrix. Rows are observations, and columns are variables. Could be a vector if there's only one observation. |
rv |
Regular vine object |
This function is a wrapper for
rvinellkv.trunc2
in the CopulaModel
package.
Vector of length = number of observations in dat
, representing
the evaluated joint density of the variables in G
.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | set.seed(123)
G <- AtoG(CopulaModel::Cvinearray(4))[1:3, ]
copmat <- makeuppertri(c("gum", "gal", "bvtcop",
"bvncop", "frk"), row = 2, col = 4, blanks = "")
cparmat <- makeuppertri.list(c(1.5, 1.5, 0.9, 3, 0.1, 0.5),
len = c(1,1,2,1,1), row = 2, col = 4)
rv <- rvine(G=G, copmat=copmat, cparmat=cparmat)
dat <- rrvine(10, rv)
logdrvine(dat, rv)
drvine(runif(4), rv)
## The variables in G don't need to refer to all data:
u <- runif(4)
drvine(u, subset(rv, 1:2))
## ...is the same as:
drvine(u[1:2], subset(rv, 1:2))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.