Learn R Programming

brainGraph (version 2.2.0)

plot.brainGraph_resids: Plot model residuals for each brain region

Description

Check the model residuals for each brain region in a structural covariance analysis. It shows a qqplot of the studentized residuals, as output from get.resid.

Usage

# S3 method for brainGraph_resids
plot(x, regions = NULL, cols = FALSE, ...)

Arguments

x

A brainGraph_resids object (from get.resid)

regions

Character vector of region(s) to focus on; default behavior is to show summary for all regions

cols

Logical indicating whether to color by group (default: FALSE)

...

Arguments passed to brainGraph_GLM_design (optional)

Value

A list of ggplot objects

See Also

qqnorm

Other Structural covariance network functions: IndividualContributions, brainGraph_boot, brainGraph_init, brainGraph_permute, corr.matrix, get.resid, plot_volumetric

Examples

Run this code
# NOT RUN {
myresids <- get.resids(lhrh, covars)
residPlots <- plot(myresids, cols=TRUE)

## Save as a multi-page PDF
ml <- marrangeGrob(residPlots, nrow=3, ncol=3)
ggsave('residuals.pdf', ml)
# }

Run the code above in your browser using DataLab