View source: R/threeBrain-instance.R
rave_brain | R Documentation |
Create 3D visualization of the brain and visualize with modern web browsers
rave_brain(
subject,
surfaces = "pial",
use_141 = TRUE,
recache = FALSE,
clean_before_cache = FALSE,
compute_template = FALSE,
usetemplateifmissing = FALSE,
include_electrodes = TRUE
)
subject |
character, list, or |
surfaces |
one or more brain surface types from |
use_141 |
whether to use 'AFNI/SUMA' standard 141 brain |
recache |
whether to re-calculate cache; only should be used when the original 'FreeSurfer' or 'AFNI/SUMA' files are changed; such as new files are added |
clean_before_cache |
whether to clean the original cache before
|
compute_template |
whether to compute template mappings; useful when template mapping with multiple subjects are needed |
usetemplateifmissing |
whether to use template brain when the subject
brain files are missing. If set to true, then a template (usually 'N27')
brain will be displayed as an alternative solution, and electrodes will be
rendered according to their |
include_electrodes |
whether to include electrode in the model; default is true |
A 'threeBrain'
instance if brain is found or
usetemplateifmissing
is set to true; otherwise returns NULL
# Please make sure DemoSubject is correctly installed
# The subject is ~1GB from Github
if(interactive()){
brain <- rave_brain("demo/DemoSubject")
if( !is.null(brain) ) { brain$plot() }
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.