phatInterval: Calculates coverage probabilities of \hat p

Description Usage Arguments Details Value See Also Examples

View source: R/2DLTfunctions.r

Description

Calculate coverage probabilities of \hat p using the delta method and assuming a log-normal error distribution.

Usage

1
phatInterval(fit, type = "LOGNORM", interval = 0.95)

Arguments

fit

object resulting from a call of fityx (see details)

type

LOGNORM log-normal confidence intervals; NORM normal confidence intervals.

interval

the interval used to determine coverage probability

Details

In the call of fityx in the fit argument must have hessian=TRUE

Value

a data frame of p phat, and CV[phat], interval, lower bound returned.

See Also

phat fityx

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
## Not run: 
ystart=4;w=1
hr=h2; b=log(c(0.75,1))
pi.x=pi.norm; logphi=c(0.5,log(0.2))
N=50 #true number of animals
#generate some observations
simDat=simXY(N=N,pi.x=pi.x,logphi=logphi,
hr=hr,b=b,w=w,ystart=ystart)
x=simDat$locs$x; y=simDat$locs$y 
est.yx=fityx(y,x,b,hr,ystart,pi.x,logphi,w)
phatInterval(fit=est.yx,interval=0.95)

## End(Not run)     

david-borchers/LT2D documentation built on Aug. 17, 2020, 1:37 a.m.