Usage
MCdof(x, ntrials = 5000, field.sig = 0.05, zfun = "rnorm", zfun.args = NULL, which.test = c("t", "Z", "cor.test"), verbose = FALSE, ...)
sig.cor.t(r, len = 40, ...)
sig.cor.Z(r, len = 40, H0 = 0)
fisherz(r)
Arguments
x
n X m numeric matrix whose rows represent temporal points, and whose columns are spatial locations.
ntrials
numeric/integer giving the number of times to generate random samples of size n, and correlate them with the columns of x
.
field.sig
numeric between 0 and 1 giving the desired fields significance level.
zfun
character naming a random number generator that takes n
(the size of the sample to be drawn) as an argument, and any other arguments necessary.
zfun.args
list object giving the values for additional arguments to the function named by zfun
.
which.test
character naming which type of test to do (default, "t", is a t-test, calls sig.cor.t
). "Z" does Fisher's Z transform (calls sig.cor.Z
). "cor.test" calls cor.test
giving more options, but is also considerably slowe
r
numeric giving the correlation value(s).
len
numeric giving the size of the data for the test.
H0
numeric giving the null hypothesis value (not used by MCdof
).
verbose
logical, should progress information (including total run time) be printed to the screen?
...
optional arguments to sig.cor.t
(not used), sig.cor.Z
, or cor.test
depending on argument which.test
.