parameter of the (zero-truncated) Poisson distribution
theta
copula parameter
family
an integer defining the bivariate copula family: 1 = Gauss, 3 = Clayton, 4=Gumbel, 5=Frank
max.y
upper value for the conditional (zero truncated) Poisson variable, see below for more details
eps
precision, see below for more details
zt
logical. If zt=TRUE, we use a zero-truncated Poisson variable. Otherwise, we use a Poisson variable. Default is TRUE.
Value
n samples, stored in a $n \times 2$ matrix
Details
For a Gamma distributed variable X and a (zero truncated) Possion variable Y, we sample from their joint distribution that is given by the density function
$$f_{XY}(x,y)=f_X(x) \left(D_u(F_Y(y),F_X(x)|\theta) - D_u(F_Y(y-1),F_X(x)|\theta) \right)\,.$$Here $D_u$ is the h-function of a copula famila family with copula parameter theta. First, we sample n observations x from the marginal Gamma distribution. Second, for each x, we then sample an observation from the conditional distribution of Y given X=x. In the second step, the conditional distribution is evaluated up to the maximum of max.y and the smallest integer > y.max for which the conditional probability is smaller than eps.
References
N. Kraemer, E. Brechmann, D. Silvestrini, C. Czado (2013): Total loss estimation using copula-based regression models. Insurance: Mathematics and Economics 53 (3), 829 - 839.
library(VineCopula)
n<-100# number of observationsmu<-1000delta<-0.09lambda<-2.5family<-1theta<-BiCopTau2Par(tau=0.5,family=family)
my.data<-simulate_joint(n,mu,delta,lambda,theta,family)