mmdt.to.brain: Visualize MMDT Results in a Subject's Brain Space

Description Usage Arguments Value Examples

View source: R/mmdt.to.brain.R

Description

This function maps mmdt results back onto subjects' brain image domains for visualization and exploration purposes.

Usage

1
2
3
mmdt.to.brain(mmdt.results, type = "t-statistic", mc.adjust = "BH",
  mask, modal1, modal2, modal3 = NULL, modal4 = NULL, modal5 = NULL,
  modal6 = NULL)

Arguments

mmdt.results

an object resulting from the 'mmdt' command.

type

type of image to be produced. Can be "t-statistic" or "significance". Default is "significance".

mc.adjust

if type="significance", this states which adjustment method to use to determine significance.

mask

a string that gives a .nii or .nii.gz filename for the subject's mask. Mask will demarcate which voxels will be included, should be coded by TRUE/FALSE or 1/0, and should be the same as the masks used to conduct the mmdt analyses.

modal1

a string that gives a .nii or .nii.gz filename for a subject's given imaging modality. At least two modalities (modal1 and modal2) must be entered. Up to 6 can be included. The same modalities used in the mmdt analyses should be entered here, in the same order.

modal2

see 'modal1' description

modal3

see 'modal1' description

modal4

see 'modal1' description

modal5

see 'modal1' description

modal6

see 'modal1' description

Value

A nifti image in a subject's brain space, in which voxel intensities represent either the t-statistic or significance of the group difference test at the given voxels' locations within the density space. Importantly, statistics are not to be interpreted in the brain space; these values are only for visualization of where specific voxel intensity profiles fall within subjects' images.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
## Not run: 
masks = c("mask01.nii", "mask02.nii", "mask03.nii", "mask04.nii")
t1s = c("t101.nii", "t102.nii", "t103.nii", "t104.nii")
flairs = c("flair01.nii", "flair02.nii", "flair03.nii", "flair04.nii")
ids = c(1, 2, 3, 4)
groups = c(1, 1, 2, 2)

mmdt.obj = get.mmdt.obj(masks = masks, modal1 = t1s, modal2 = flairs,
                        ids = ids, groups = groups)
mmdt.results = mmdt(mmdt.obj)

tstat.mask.s1 = mmdt.to.brain(mmdt.results, type = "t-statistic",
                              mask = "mask01.nii", modal1 = "t101.nii",
                              modal2 = "flair01.nii")
sig.mask.s1 = mmdt.to.brain(mmdt.results, type = "significance",
                            mask = "mask01.nii", modal1 = "t101.nii",
                            modal2 = "flair01.nii")
writeNifti(tstat.mask.s1, file="mmdt.tstat.01.nii.gz")
writeNifti(sig.mask.s1, file="mmdt.sig.01.nii.gz")
## End(Not run)

jdwor/mmdt documentation built on April 7, 2021, 5:17 p.m.