Bivariate_LSDsim {trawl} | R Documentation |
Simulates from the bivariate logarithmic series distribution
Description
Simulates from the bivariate logarithmic series distribution
Usage
Bivariate_LSDsim(N, p1, p2)
Arguments
N |
number of data points to be simulated |
p1 |
parameter |
p2 |
parameter |
Details
The probability mass function of a random vector X=(X_1,X_2)'
following the bivariate logarithmic series distribution with parameters
0<p_1, p_2<1
with p:=p_1+p_2<1
is given by
P(X_1=x_1,X_2=x_2)=\frac{\Gamma(x_1+x_2)}{x_1!x_2!}
\frac{p_1^{x_1}p_2^{x_2}}{(-\log(1-p))},
for x_1,x_2=0,1,2,\dots
such
that x_1+x_2>0
. The simulation proceeds in two steps: First, X_1
is simulated from the modified logarithmic distribution with parameters
\tilde p_1=p_1/(1-p_2)
and \delta_1=\log(1-p_2)/\log(1-p)
. Then
we simulate X_2
conditional on X_1
. We note that
X_2|X_1=x_1
follows the logarithmic series distribution with
parameter p_2
when x_1=0
, and the negative binomial
distribution with parameters (x_1,p_2)
when x_1>0
.
Value
An N \times 2
matrix with N
simulated values from the
bivariate logarithmic series distribution