Bivariate_LSDsim: Simulates from the bivariate logarithmic series distribution

Description Usage Arguments Details Value

View source: R/SimulateDiscreteDistributions.R

Description

Simulates from the bivariate logarithmic series distribution

Usage

1
Bivariate_LSDsim(N, p1, p2)

Arguments

N

number of data points to be simulated

p1

parameter p_1 of the bivariate logarithmic series distribution

p2

parameter p_2 of the bivariate logarithmic series distribution

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{Γ(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,… 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 δ_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


trawl documentation built on Feb. 23, 2021, 1:06 a.m.