View source: R/simulateSpatialData.R
simulateSpatialData | R Documentation |
Simulate normal distributed data with spatial correlation structure
theta
(\theta
) describes how rapidly the correlation declines with respect to the distance between two voxels.
The three-dimensional coordinates of the voxels are defined as all combinations
of vector c = (1, \dots, m1/3)
, then \Sigma_\theta = \exp(-\theta K)
where K
is the matrix containing the
euclidean distances between the three-dimensional coordinates' voxels.
So, m^{1/3}
must be an integer value.
simulateSpatialData(pi0,m,n, theta, seed = NULL, power = 0.8, alpha = 0.05)
pi0 |
Numeric value in '[0,1]'. Proportion of true null hypothesis. |
m |
Numeric value. Number of variables. |
n |
Numeric value. Number of observations. |
theta |
Numeric value in '[0,1]'. Level of correlation between pairs of variables. See details |
seed |
Integer value. If you want to specify the seed. Default to to |
power |
Numeric value in '[0,1]'. Level of power. Default to 0.8. |
alpha |
Numeric value in '[0,1]'. |
Returns a matrix with dimensions m \times n
.
Angela Andreella
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.