Description Usage Arguments Details Author(s) References See Also Examples
View source: R/cudaMultireg.volume.R
cudaMultireg.volume
provides an interface to a CUDA implementation
of a Bayesian multilevel model for the analysis of brain fMRI data.
Data is processed on a slice-by-slice basis.
Data volumes in gzipped NIFTI format are used.
1 2 |
fbase |
If |
R |
number of MCMC draws |
keep |
MCMC thinning parameter: keep every keepth draw (def: 5) |
nu.e |
d.f. parameter for regression error variance prior (def: 3) |
zprior |
Boolean {T,F}; default {F} - use just a mean for |
rng |
integer {0,1,2}: type of RNG to use {0-Marsaglia Multicarry, 1-R. P. Brent xorgens, 2-Mersenne Twister MT19937-64}; (def. 0-Marsaglia Multicarry) |
rg |
rg=c(first, last): a vector containing the first and last numbers of the sequence of slices to be processed. If rg=c(NULL,NULL) (default), all slices in the volume are processed. |
swap |
logical variable (default = |
savedir |
Directory (def: |
The statistical model implemented in CUDA was specified as a Gibbs Sampler for hierarchical linear models
with a normal prior.
The main computational work is done in parallel on a CUDA capable GPU. Each thread is responsible for fitting
a general linear model at each voxel.
Data volumes are processed on a slice-by-slice basis, before reconstructing the processed volume,
using build.zstatvolume
.
The statistical model is specified in cudaMultireg.slice
.
To run the examples, the data sets from the R-package cudaBayesregData are required.
Adelino Ferreira da Silva, Universidade Nova de Lisboa, Faculdade de Ciencias e Tecnologia, Portugal, afs@fct.unl.pt.
Adelino R. Ferreira da Silva (2011). “cudaBayesreg: Parallel Implementation of a Bayesian Multilevel Model for fMRI Data Analysis.” Journal of Statistical Software, 44(4), 1–24. URL http://www.jstatsoft.org/v44/i04/.
Adelino Ferreira da Silva (2011). cudaBayesregData: Data sets for the examples used in the package cudaBayesreg, R package version 0.3-10. URL http://CRAN.R-project.org/package=cudaBayesregData.
Adelino Ferreira da Silva (2011). “A Bayesian Multilevel Model for fMRI Data Analysis.”, Computer Methods and Programs in Biomedicine, 102,(3), 238–252.
Adelino Ferreira da Silva (2010). “cudaBayesreg: Bayesian Computation in CUDA.”, The R Journal, 2/2, 48-55. URL http://journal.r-project.org/archive/2010-2/RJournal_2010-2_Ferreira~da~Silva.pdf.
Rossi, Allenby and McCulloch. Bayesian Statistics and Marketing, Chapter 3. URL http://faculty.chicagogsb.edu/peter.rossi/research/bsm.html.
Davies, R.B. (1994). Writing a matrix package in C++. In OON-SKI'94: The second annual object-oriented numerics conference, pp 207-213. Rogue Wave Software, Corvallis. URL http://www.robertnz.net/cpp\_site.html.
Richard. P. Brent. Some long-period random number generators using shifts and xors, Preprint: 2 July 2007.
Brandon Whitcher, Volker Schmid and Andrew Thornton (2011). oro.nifti: Rigorous - NIfTI Input / Output, R package version 0.2.5. URL http://CRAN.R-project.org/package=oro.nifti.
cudaMultireg.slice
,
buildzstat.volume
,
read.fmrislice
,
read.Zsegslice
,
premask
,
pmeans.hcoef
,
regpostsim
,
plot.hcoef.post
,
post.simul.hist
,
post.ppm
,
post.tseries
,
post.randeff
,
post.shrinkage.mean
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | ## Not run:
## simulation using the SPM auditory dataset "swrfM*"
cudaMultireg.volume(fbase="swrfM", R=2000, rg=c(13,16), savedir=tempdir())
buildzstat.volume(fbase="swrfM", rg=c(13,16))
post.overlay(fbase="swrfM", vreg=2, rg=c(13,16), view="axial")
##
## Random effects simulation using the SPM auditory dataset "swrfM*"
cudaMultireg.volume(fbase="swrfM", R=2000, zprior=TRUE, rng=1,
rg=c(17,21), savedir=tempdir())
buildzstat.volume(fbase="swrfM", rg=c(17,21))
post.overlay(fbase="swrfM", vreg=2, rg=c(17,21), view="axial")
##
## Simulation using the visual/auditory test dataset "fmri"
cudaMultireg.volume(fbase="fmri", R=2000, savedir=tempdir())
buildzstat.volume(fbase="fmri", vreg=2)
post.overlay(fbase="fmri", vreg=2, view="axial")
buildzstat.volume(fbase="fmri", vreg=4)
post.overlay(fbase="fmri", vreg=4, view="axial")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.