Print a species_mix model object.
# S3 method for species_mix print(x, ...)
x | A model object. |
---|---|
\dots | Ignored |
#Print information about a species_mix model # \donttest{ library(ecomix) set.seed(42) sam_form <- stats::as.formula(paste0('cbind(',paste(paste0('spp',1:20), collapse = ','),")~x1+x2")) sp_form <- ~ 1 beta <- matrix(c(-2.9,-3.6,-0.9,1,.9,1.9),3,2,byrow=TRUE) dat <- data.frame(y=rep(1,100),x1=stats::runif(100,0,2.5), x2=stats::rnorm(100,0,2.5)) dat[,-1] <- scale(dat[,-1]) simulated_data <- species_mix.simulate(archetype_formula = sam_form,species_formula = sp_form, data = dat,beta=beta,family="bernoulli")#>fm1 <- species_mix(archetype_formula = sam_form,species_formula = sp_form, data = simulated_data, family = 'bernoulli', nArchetypes=3)#>#>#>#>#>#>#>#>#>#>#>#>#>#>#> initial value 819.837658 #> iter 10 value 819.706575 #> final value 819.703416 #> converged#> bernoulli species_mix model #> #> Pi #> Archetype1 Archetype2 Archetype3 #> 0.25 0.40 0.35 #> #> Coefficients #> $alpha #> spp1 spp2 spp3 spp4 spp5 spp6 spp7 #> -0.8017227 -1.6402031 -0.5752349 -1.0844096 -1.0206816 -1.1776675 -0.7334905 #> spp8 spp9 spp10 spp11 spp12 spp13 spp14 #> -1.2036925 -1.6417828 -0.1856826 -0.8567273 -1.3909615 -0.7040057 -0.7040057 #> spp15 spp16 spp17 spp18 spp19 spp20 #> -0.8934080 -0.3780058 -1.3858329 -1.0552211 -1.2036925 -0.4298861 #> #> $beta #> x1 x2 #> Archetype1 -2.9107151 -3.5524869 #> Archetype2 -0.8299319 0.9551632 #> Archetype3 0.9916068 1.9873571 #>