Last chance! 50% off unlimited learning
Sale ends in
fitmix(data, width, mix.terms = 1, pt = FALSE, model.formula = "~1", initialvalues = NULL, showit = 0, ctrl.options = c(maxit = 10000), opt.method = "BFGS+SANN", usegrad = TRUE, ftype = "hn")
data.frame
containing the distances
and covariates to be used in the analusis (see Details).NULL
. See
mmds.pars
for more information.optim
. Defaults to c(maxit=10000)
.ds.mixture
model object.
data
should be a data.frame
with (at least)
a column named distance
. Any covariates given in
model.formula
should be named in data
. Note
that rows with distance
greater than width
will be discarded. See step.ds.mixture
for AIC selection for
the number of mixture components.summary.ds.mixture
step.ds.mixture
plot.ds.mixture
sim.mix
mmds.gof
ds.mixture
mmds.gof
fitmix
mmds.pars
step.ds.mixture
library(mmds)
set.seed(0)
## simulate some line transect data from a 2 point mixture
sim.dat<-sim.mix(c(-0.223,-1.897,inv.reparam.pi(0.3)),2,100,1)
## fit the model
fit.sim.dat<-fitmix(sim.dat,1,2)
## what happened?
summary(fit.sim.dat)
Run the code above in your browser using DataLab