moran | R Documentation |
This code was modified from the original in the spdep package.
moran(x, listw, comp = NULL, zero.policy = FALSE, NAOK = FALSE, demean = TRUE)
x |
A matrix of variables to compute the bivariate Moran's I |
listw |
A listw object specifying the weighting matrix. |
comp |
A vector of integers, strings, or factors indicating broad tissue compartments in which to compute Moran's I. |
zero.policy |
How to deal with zones without neighbors. If TRUE assign zero to the lagged value of zones without neighbours, if FALSE assign NA |
NAOK |
If TRUE, NAs are removed in computations. |
demean |
If TRUE demean columns of x. Might not want to if x is dummy variables. |
Returns a list of matrices, where each matrix is the multivariate Moran's I for each tissue compartment.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.