gate_rectangle_draw constructs an interactive plotting window to allow
manual selection of the co-ordinates of a rectangle gate(s) (through mouse
click) which are constructed into
rectangleGate objects and stored
in a filters list. Simply select 2
diagonal co-ordinates to construct the rectangleGate(s).
gate_rectangle_draw(fr, alias = NULL, channels, plot = TRUE, label = TRUE, ...)
| fr | a |
|---|---|
| alias | the name(s) of the populations to be gated. If multiple
population names are supplied (e.g. |
| channels | vector of channel names to use for plotting, can be of length 1 for 1-D density histogram or length 2 for 2-D scatter plot. |
| plot | logical indicating whether the data should be plotted. This feature allows for constructing gates of different types over existing plots which may already contain a different gate type. |
| label | logical indicating whether to include
|
| ... | additional arguments for |
afilters list containing the
constructed rectangleGate
object(s).
# NOT RUN { # Copy and paste into console to interactively draw gates library(CytoRSuiteData) # Load in samples to flowSet fs <- Activation # Transform fluorescent channels fs <- transform(fs, estimateLogicle(fs[[4]], cyto_fluor_channels(fs))) # Get polygonGate using gate_rectangle_draw - add contour lines rg <- gate_rectangle_draw(fs[[4]], alias = "Cells", channels = c("FSC-A", "SSC-A"), contour_lines = 15 ) # rg is a filters object - extract rectangleGate using `[[` rg[[1]] # }