Package 'OBMbpkg'

Title: Estimate the Population Size for the Mb Capture-Recapture Model
Description: Applies an objective Bayesian method to the Mb capture-recapture model to estimate the population size N. The Mb model is a class of capture-recapture methods used to account for variations in capture probability due to animal behavior. Under the Mb formulation, the initial capture of an animal may effect the probability of subsequent captures due to their becoming "trap happy" or "trap shy."
Authors: Dan Zheng
Maintainer: John Snyder <[email protected]>
License: GPL-3
Version: 1.0.0
Built: 2025-03-12 03:12:49 UTC
Source: https://github.com/cran/OBMbpkg

Help Index


Objective Bayesian Analysis for the Mb Capture-Recapture Model

Description

Applies an objective Bayesian method on to the Mb capturere-capture model to estimate the population size N.

Usage

OBMb(k, n, M, x, CI1 = 0.025, CI2 = 0.975, max = 10000, IFMLE = TRUE)

Arguments

k

Number of sampling occasions

n

Total number of distinct animals captured

M

Number of marked animals captured in all sampling occasions

x

The number of new animals captured at each sampling occasion

CI1

Lower confidence level

CI2

Upper confidence level

max

The maximum of function evaluations used for computing the integrated likelihood L(N|X)

IFMLE

Logical, will also print MLE results if TRUE

Value

  • EMEAN: Posterior mean for N

  • EMEDIAN: Posterior median for N

  • OBCI: Credible interval values based on the quantiles specified by CI1 and CI2

  • MLE: If IFMLE==TRUE, this is the frequentist MLE for N

  • Ep: If IFMLE==TRUE, the frequentist estimate of the initial capture probability p

  • MLECI: If IFMLE==TRUE, confidence interval for the MLE quantile specified by CI2

Examples

# Data simulation example
k=10
tN=600   #True N
p=0.06
JN=rep(0,k+1)

N=rep(0,k)
x=rep(0,k)
for (j in 1:k){
  N[j]=tN-JN[j]
  x[j]=rbinom(1,N[j],p)
  JN[j+1]=JN[j]+x[j]
}
M=sum(JN[1:k])
n=JN[k+1]

OBMb(k=k,n=n,M=M,x=x)

#Deer mouse example from Otis et al 1978
Data<-c(15, 8, 6, 3, 3, 3)   #new animals captured at each sampling occasion

OBMb(k=6,n=38,M=134,x=Data)