fmrireport generates publication-oriented PDF reports for fitted
fmrireg::fmri_lm models. It also provides a standalone cluster_table()
function for building COBIDAS-compliant activation tables from any statistical
brain volume.
Full documentation and vignettes: https://bbuchsbaum.github.io/fmrireport/
# install.packages("remotes")
remotes::install_github("bbuchsbaum/fmrireport")library(fmrireport)
library(neuroim2)
# Create a synthetic t-stat volume
set.seed(42)
sp <- NeuroSpace(c(64, 64, 40), spacing = c(3, 3, 3))
arr <- array(rnorm(64 * 64 * 40), c(64, 64, 40))
arr[20:28, 25:33, 15:22] <- arr[20:28, 25:33, 15:22] + 5
vol <- NeuroVol(arr, sp)
ct <- cluster_table(vol, threshold = 3.0, stat_type = "t", df = 50)
print(ct)library(fmrireg)
# fit <- fmri_lm(...)
# report(fit, output_file = "my_analysis.pdf")Rscript inst/examples/fmri_lm_report_demo.R /tmp/fmrireport-report-examplesThis writes three complete example reports (matrix, spatial, spatial+atlas).