Description Usage Arguments Value See Also Examples
View source: R/brainview_magick.R
Create a tight layout view of coloredmeshes from several angles. Creates separate 'sd_<angle>' images, then crops and finally merges them into a single output image with image magick. The 'coloredmeshes' to pass to this function are usually obtained by running any 'vis*' function (like vis.subject.morph.native, vis.subject.morph.standard, vis.subject.label, vis.subject.annot, and others). That means you can use this function to visualize all kinds of data, e.g., morphometry data in native and standard space, labels, and brain atlases.
1 2 3 4 5 6 7 8 9 10  | vislayout.from.coloredmeshes(
  coloredmeshes,
  view_angles = get.view.angle.names(angle_set = "t4"),
  rgloptions = rglo(),
  rglactions = list(),
  style = "default",
  output_img = "fsbrain_arranged.png",
  silent = FALSE,
  grid_like = TRUE
)
 | 
coloredmeshes,  | 
 list of coloredmesh. A coloredmesh is a named list as returned by the 'coloredmesh.from*' functions (like   | 
view_angles | 
 list of strings. See   | 
rgloptions | 
 option list passed to   | 
rglactions | 
 named list. A list in which the names are from a set of pre-defined actions. The values can be used to specify parameters for the action.  | 
style | 
 character string, a rendering style, e.g., 'default', 'shiny' or 'semitransparent'. Alternatively, a named list of style parameters (see   | 
output_img | 
 string, path to the output file. Defaults to "fsbrain_arranged.png"  | 
silent | 
 logical, whether to suppress all messages  | 
grid_like | 
 logical, whether to arrange the images in a grid-like fashion. If FALSE, they will all be merged horizontally. Passed to   | 
named list, see arrange.brainview.images for details
Other visualization functions: 
vis.color.on.subject(),
vis.data.on.fsaverage(),
vis.data.on.subject(),
vis.labeldata.on.subject(),
vis.mask.on.subject(),
vis.region.values.on.subject(),
vis.subject.annot(),
vis.subject.label(),
vis.subject.morph.native(),
vis.subject.morph.standard(),
vis.symmetric.data.on.subject()
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16  | ## Not run: 
   fsbrain::download_optional_data();
   subjects_dir = fsbrain::get_optional_data_filepath("subjects_dir");
   # Use any vis function to get coloredmeshes. You can visualize morphometry,
   #  labels, an atlas, whatever. You can suppress the view unless you need it.
   coloredmeshes = vis.subject.morph.native(subjects_dir, "subject1", "thickness",
    cortex_only=TRUE, rglactions=list("clip_data"=c(0.05, 0.95)),
    views=NULL);
   # The meshes contain the surface, data, and color information and can be
   #  visualized. You could adapt the rendering style while doing so:
   vislayout.from.coloredmeshes(coloredmeshes, style='shiny');
   # You could change the rendering style on a per-mesh basis.
   coloredmeshes[[1]]$style = list("shininess"=50, alpha=0.5);
   vislayout.from.coloredmeshes(coloredmeshes, style='from_mesh');
## End(Not run)
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.