forward_warp: Forward warp back to atlas space

Description Usage Arguments Value See Also

View source: R/forward_warp.R

Description

Loop through all segmented cells and perform forward warp loop back onto atlas space using registration and segmentation data. Options for plotting a schematic plot and saving forward warp images. For a whole brain, this function should be used after the segmentation list segs has been cleaned of duplicate cell counts. Note: if the imaging dataset is large this will be a time intensive process. Processing time will be printed once the function is finished.

Usage

1
2
3
4
5
6
forward_warp(setup, segs, regis, filetype = c("tif", "tiff", "wmf",
  "emf", "png", "jpg", "jpeg", "bmp", "ps", "eps", "pdf"),
  savewarp = TRUE, saveschematic = TRUE, plane = "coronal",
  title = FALSE, mm.grid = TRUE, dev.size = c(5.4, 4.465),
  pch = 21, cex = 0.5, col = "black", scale.bar = FALSE,
  region.colors = TRUE)

Arguments

setup

(required) Setup list from setup_pl().

segs

(required) Segmentation data.

regis

(required) Registration data.

filetype

(optional, default = "tif") Image type to save as. See the type argument in the function savePlot(). Options: "tif", "tiff", "wmf", "emf", "png", "jpg", "jpeg", "bmp","ps", "eps", "pdf"

savewarp

(optional, default = TRUE) Save forward warp plot image in folder 'setup$savepaths$out_segmentation_warps'.

saveschematic

(optional, default = TRUE) Save schematic plot images in folder 'setup$savepaths$out_segmentation_schem'.

plane

(optional, default = "coronal") Atlas plane to register to. options: "coronal", "sagittal"

title

(optional, default = FALSE) Title for the schematic plot.

mm.grid

(optional, default = TRUE) Plot grid in schematic plot.

dev.size

(optional, default = c(5.4, 4.465)). See same argument from wholebrain::schematic.plot().

pch

(optional, default = 21) Graphical parameter for point shape.

cex

(optional, default = 0.5) Graphical parameter for text size.

col

(optional, default = "black") Graphical parameter for color.

scale.bar

(optional, default = TRUE) Display a measure bar in the schematic plot

region.colors

(optional, default = TRUE) Display Allen Brain Atlas colors in schemetic plot.

Value

Returns dataset a variable storing all mapped segmentation data to registration data.

See Also

See also wholebrain::schematic.plot().


ashekara/ratSMART documentation built on June 25, 2020, 12:02 a.m.