Learn R Programming

unmarked (version 0.8-5)

modSel: Model selection results from an unmarkedFitList

Description

Model selection results from an unmarkedFitList

Arguments

object
an object of class "unmarkedFitList" created by the function fitList.
nullmod
optional character naming which model in the fitList contains results from the null model. Only used in calculation of Nagelkerke's R-squared index.

Value

  • A S4 object with the following slots
  • EstimatesMatrix containing parameter estimates for each model
  • SEMatrix containing standard errors for model parameters
  • Fulldata.frame with formula, estimates, standard errors and model selection information. Converge is optim convergence code. CondNum is model condition number. Rsq is Nagelkerke's (1991) R-squared index, which is only returned when the nullmod argument is specified.

References

Nagelkerke, N.J.D. (2004) A Note on a General Definition of the Coefficient of Determination. Biometrika 78, pp. 691-692.

Examples

Run this code
data(linetran)
(dbreaksLine <- c(0, 5, 10, 15, 20)) 
lengths <- linetran$Length * 1000

ltUMF <- with(linetran, {
	unmarkedFrameDS(y = cbind(dc1, dc2, dc3, dc4), 
	siteCovs = data.frame(Length, area, habitat), dist.breaks = dbreaksLine,
	tlength = lengths, survey = "line", unitsIn = "m")
	})

fm1 <- distsamp(~ 1 ~1, ltUMF)
fm2 <- distsamp(~ area ~1, ltUMF)
fm3 <- distsamp( ~ 1 ~area, ltUMF)

fl <- fitList(Null=fm1, A.=fm2, .A=fm2)
fl

(ms <- modSel(fl, nullmod="Null"))

ms@Estimates
ms@SE
ms@Full

Run the code above in your browser using DataLab