unmarkedFit-class | R Documentation |
Contains fitted model information which can be manipulated or extracted using the methods described below.
fitType
:Object of class "character"
call
:Object of class "call"
formula
:Object of class "formula"
data
:Object of class "unmarkedFrame"
sitesRemoved
:Object of class "numeric"
estimates
:Object of class "unmarkedEstimateList"
AIC
:Object of class "numeric"
opt
:Object of class "list"
containing results from
optim
negLogLike
:Object of class "numeric"
nllFun
:Object of class "function"
knownOcc
:unmarkedFitOccu only: sites known to be occupied
K
:unmarkedFitPCount only: upper bound used in integration
mixture
:unmarkedFitPCount only: Mixing distribution
keyfun
:unmarkedFitDS only: detection function used by distsamp
unitsOut
:unmarkedFitDS only: density units
signature(x = "unmarkedFit", i = "ANY", j = "ANY",
drop = "ANY")
: extract one of names(obj), eg 'state' or 'det'
signature(obj = "unmarkedFit")
: back-transform
parameters to original scale when no covariate effects are modeled
signature(object = "unmarkedFit")
: returns parameter
estimates. type can be one of names(obj), eg 'state' or 'det'.
If altNames=TRUE estimate names are more specific.
signature(object = "unmarkedFit")
: Returns confidence
intervals. Must specify type and method (either "normal" or "profile")
signature(object = "unmarkedFit")
: returns expected
values of Y
signature(object = "unmarkedFit")
: extracts data
signature(object = "unmarkedFit")
: calculates and extracts
expected detection probabilities
signature(object = "unmarkedFit")
: calculates and extracts
expected false positive detection probabilities
signature(object = "unmarkedFit")
: calculates and extracts
expected probabilities a true positive detection was classified as certain
signature(object = "unmarkedFit")
: Returns hessian
matrix
signature(obj = "unmarkedFit",
coefficients = "matrixOrVector")
: Returns estimate and SE on original
scale when covariates are present
signature(object = "unmarkedFit")
: Same as coef(fit)?
signature(x = "unmarkedFit")
: Names of parameter levels
signature(object = "unmarkedFit")
: returns negative
log-likelihood used to estimate parameters
signature(object = "unmarkedFit")
: Parametric
bootstrapping method to assess goodness-of-fit
signature(x = "unmarkedFit", y = "missing")
: Plots
expected vs. observed values
signature(object = "unmarkedFit")
: Returns predictions
and standard errors for original data or for covariates in a new
data.frame
signature(fitted = "unmarkedFit")
: used by confint
method='profile'
signature(object = "unmarkedFit")
: returns residuals
signature(object = "unmarkedFit")
: returns number
of sites in sample
signature(obj = "unmarkedFit")
: returns standard errors
signature(object = "unmarkedFit")
: concise results
signature(object = "unmarkedFit")
: results with more
details
signature(object = "unmarkedFit")
: refit model with
changes to one or more arguments
signature(object = "unmarkedFit")
: returns
variance-covariance matrix
signature(object="unmarkedFitColExt")
:
Returns the smoothed trajectory from a colonization-extinction
model fit. Takes additional logical argument mean which specifies
whether or not to return the average over sites.
signature(object="unmarkedFitColExt")
:
Returns the projected trajectory from a colonization-extinction
model fit. Takes additional logical argument mean which specifies
whether or not to return the average over sites.
signature(object="unmarkedFit")
:
Returns the log-likelihood.
signature(m1="unmarkedFit", m2="unmarkedFit")
:
Returns the chi-squared statistic, degrees-of-freedom, and p-value from
a Likelihood Ratio Test.
This is a superclass with child classes for each fit type
showClass("unmarkedFit")
# Format removal data for multinomPois
data(ovendata)
ovenFrame <- unmarkedFrameMPois(y = ovendata.list$data,
siteCovs = as.data.frame(scale(ovendata.list$covariates[,-1])),
type = "removal")
# Fit a couple of models
(fm1 <- multinomPois(~ 1 ~ ufc + trba, ovenFrame))
summary(fm1)
# Apply a bunch of methods to the fitted model
# Look at the different parameter types
names(fm1)
fm1['state']
fm1['det']
# Coefficients from abundance part of the model
coef(fm1, type='state')
# Variance-covariance matrix
vcov(fm1, type='state')
# Confidence intervals using profiled likelihood
confint(fm1, type='state', method='profile')
# Expected values
fitted(fm1)
# Original data
getData(fm1)
# Detection probabilities
getP(fm1)
# log-likelihood
logLik(fm1)
# Back-transform detection probability to original scale
# backTransform only works on models with no covariates or
# in conjunction with linearComb (next example)
backTransform(fm1, type ='det')
# Predicted abundance at specified covariate values
(lc <- linearComb(fm1, c(Int = 1, ufc = 0, trba = 0), type='state'))
backTransform(lc)
# Assess goodness-of-fit
parboot(fm1)
plot(fm1)
# Predict abundance at specified covariate values.
newdat <- data.frame(ufc = 0, trba = seq(-1, 1, length=10))
predict(fm1, type='state', newdata=newdat)
# Number of sites in the sample
sampleSize(fm1)
# Fit a new model without covariates
(fmNull <- update(fm1, formula = ~1 ~1))
# Likelihood ratio test
LRT(fm1, fmNull)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.