R: Random sample generation of variables 'X' and 'Y' marginal...
BiCopGen
R Documentation
Random sample generation of variables X and Y marginal
distributions for the Archimedean copula
Description
Generates a random sample of variables X and Y
of the marginal distribution for the Archimedean copula. X and Y
are of the same size and can be censored.
Usage
BiCopGen(x, rodiny = c("weibull", "weibull"), rodina = "gumbel", No,
cens = TRUE, bicens = TRUE, digi = 0)
Arguments
x
vector of these parameters: x[1], x[3]shape ("weibull" or "gamma")
or mean ("norm") or meanlog ("lognormal") x[2], x[4]scale ("weibull" or "gamma")
or sd ("norm") or sdlog ("lognormal") x[5] copula parameter
rodiny
vector of length 2 of names of the marginal distributions.
Distributions can be "weibull", "gamma", "norm", "lnorm".
"norm" is the name for the Normal distribution.
"lnorm" is the name for the Lognormal distribution.
rodina
copula family. Currently supported families
are "gumbel", "clayton" and "frank".
No
sample size
cens
cens = TRUE ... censored sample
bicens
if both bicens and cens are TRUE,
both X and Y are censored.
If cens is TRUE and bicens is FALSE,
one of the X or Y can be uncensored
digi
number of decimal places in the output X and Y
Details
Random censoring using distribution function having the same
specifications as the original uncensored distribution.
Value
A list with the following components:
X, Y
vectors sizes of No and having
digi number of decimal places.
dX
vector size of No and consisting of 0 or 1.
If X[i] is censored, dX[i] = 0.
dY
Vector size of No and consisting of 0 or 1.
If Y[i] is censored, dY[i] = 0.