BMfast2.Rd
Takes a binary matrix of voxels and a vector of behavior and runs Brunner-Munzel tests on each voxel. This is a fast function that corrects for infinite values with a similar approach as the nparcomp package.
BMfast2(X, y, computeDOF = TRUE)
X | binary matrix of voxels (columns) for all subjects (rows) |
---|---|
y | vector of behavioral scores. |
computeDOF | (true) chooses whether to compute degrees of freedom. Set to false to save time during permutations. |
List with two vectors:
statistic
- BM values
dfbm
- degrees of freedom
set.seed(1234) lesmat = matrix(rbinom(40,1,0.2), ncol=2) set.seed(1234) behavior = rnorm(20) test = LESYMAP::BMfast2(lesmat, behavior) test$statistic[,1] # -2.0571825 -0.8259754#> [1] -2.0571825 -0.8259754test$dfbm[,1] # 16.927348 7.563432#> [1] 16.927348 7.563432