thresh {bayess} | R Documentation |
Bound for the accept-reject algorithm in Chapter 5
Description
This function is used in ardipper
to determine the bound for
the accept-reject algorithm simulating the non-standard conditional distribution
of r_1
.
Usage
thresh(k, n1, c2, c3, r2, q1)
Arguments
k |
current proposal for the number of individuals vanishing between the first and second experiments |
n1 |
first capture population size |
c2 |
number of individuals recaptured during the second experiment |
c3 |
number of individuals recaptured during the third experiment |
r2 |
number of individuals vanishing between the second and third experiments |
q1 |
probability of disappearing from the population |
Details
This upper bound is equal to
\frac{{n_1-c_2 \choose k} {n_1-k \choose c_3+r_2}}{{\bar r\choose k}}
Value
numerical value of the upper bound, to be compared with the uniform random draw
See Also
Examples
## Not run: if (runif(1) < thresh(y,n1,c2,c3,r2,q1))
[Package bayess version 1.6 Index]