lsm_ttest | R Documentation |
Lesion to symptom mapping performed on a prepared matrix. T-tests are performed using each column of the matrix to split the behavioral scores in two groups. If var.equal=TRUE the Welch test is performed instead.
lsm_ttest(lesmat, behavior, var.equal = T, alternative = "greater",
checkAssumptions = TRUE, showInfo = TRUE, ...)
lesmat |
binary matrix (0/1) of voxels (columns) and subjects (rows). |
behavior |
vector of behavioral scores. |
var.equal |
logical (default=TRUE) should the variance between groups considered equal (t-test) or unequal (Welch test). |
alternative |
(default='greater') Sets the expected
relationship between voxel value and behavior. By default
voxels with zero are not lesioned, and behavior is expected to
be higher, thus |
checkAssumptions |
Check whether t-test assumptions are met for every voxel |
showInfo |
logical (default=TRUE), display time-stamped info messages |
... |
other arguments received from |
List of objects returned:
statistic
- vector of statistical values
pvalue
- vector of pvalues
zscore
- vector of zscores
Dorian Pustina
{
set.seed(123)
lesmat = matrix(rbinom(200,1,0.5), ncol=2)
set.seed(123)
behavior = rnorm(100)
result = lsm_ttest(lesmat, behavior)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.