View source: R/gs_gate_transform_interactive.R
gs_gate_transform_interactive | R Documentation |
CAUTION: Experimental Function. Still probably has bugs.
gs_gate_transform_interactive( gs, node, sample = 1, dims = list("FSC-A", "SSC-A"), overlayGates = NULL )
gs |
The GatingSet containing the gate you want to adjust |
node |
String specifying the (unambiguous) name of the node to adjust |
sample |
Numeric specifying which sample in the GatingSet to use for example purposes. Note that the adjusted gate will be applied to ALL samples, not just this one. |
dims |
List of characters specifying channel names or marker names to plot on x and y axis. Defaults to list("FSC-A", "SSC-A") mostly just to make the format clear. |
overlayGates |
(optional) string or character vector specifying names of gates to draw on the plot but NOT adjust, for ease of adjusting a gate in the vicinity of other gates. Leave NULL to not overlay any gates. |
Call gs_gate_transform_interactive to open a small Shiny app to allow for manual, interactive adjustments to gates. Currently only supports rectangleGates and polygonGates.
NULL, but silently deletes the old gate, adds the new one, and recomputes the GatingSet.
path_to_fcs <- system.file("extdata", package = "flowGate") fs <- read.flowSet(path = path_to_fcs, pattern = ".FCS$", full.names = TRUE) gs <- GatingSet(fs) if(interactive()) { # only run in interactive sessions gs_gate_interactive(gs, filterId = "Lymphocytes", dims = list("FSC-H", "SSC-H")) # Adds a lymphocytes gate to the GatingSet (exactly as in gs_gate_interactive) gs_gate_transform_interactive(gs, filterId = "Lymphocytes", dims = list("FSC-H", "SSC-H")) } # Opens a window to adjust the gate manually
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.