Description Usage Arguments See Also Examples
print.bayescomm
prints a brief summary of a bayescomm
object.
1 2 |
x |
a |
... |
further arguments to pass to |
1 2 3 |
BC> # create fake data
BC> n <- 100
BC> nsp <- 4
BC> k <- 3
BC> X <- matrix(c(rep(1, n), rnorm(n * k)), n) # covariate matrix
BC> W <- matrix(rnorm(nsp * nsp), nsp)
BC> W <- W %*% t(W) / 2 # true covariance matrix
BC> B <- matrix(rnorm(nsp * (k + 1), 0, 3), nsp) # true covariates
BC> mu <- apply(B, 1, function(b, x) x %*% b, X) # true mean
BC> e <- matrix(rnorm(n * nsp), n) %*% chol(W) # true e
BC> z <- mu + e # true z
BC> Y <- ifelse(z > 0, 1, 0) # true presence/absence
BC> # run BC (after removing intercept column from design matrix)
BC> m1 <- BC(Y, X[, -1], model = "full", its = 100)
model type: full
observations: 100
species: sp1 sp2 sp3 sp4
covariates: intercept cov1 cov2 cov3
iterations: 100 thin: 1 discarded: 0model type: full
observations: 100
species: sp1 sp2 sp3 sp4
covariates: intercept cov1 cov2 cov3
iterations: 100 thin: 1 discarded: 0
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.