Manually draw gates around populations for analysis of flow cytometry data.
# S4 method for flowSet gate_draw(x, select = NULL, channels = NULL, alias = NULL, type = "polygon", display = 1/length(x), axis = "x", density_smooth = 1.5, label = TRUE, plot = TRUE, ...)
x | object of class |
---|---|
select | vector containing the indices of samples within gs to use for plotting. |
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. |
alias | the name(s) of the populations to be gated. If multiple
population names are supplied (e.g. |
type | vector of gate type names used to construct the gates. Multiple
gate types are supported but should be accompanied with an |
display | numeric [0,1] to control the percentage of events to be
plotted. Specifying a value for |
axis | indicates whether the |
density_smooth | smoothing factor passed to
|
label | logical indicating whether to include
|
plot | logical indicating whether a plot should be drawn, set to
|
... | additional arguments for |
a filters
list containing the
drawn gate objects.
# NOT RUN { library(CytoRSuiteData) # Load in samples fs <- Activation # draw gates using gate_draw - add contour lines & overlay control gate_draw(fs, channels = c("FSC-A", "SSC-A"), alias = "Cells", type = "polygon", contour_lines = 15, overlay = fs[[1]] ) # gt is a filters object containing the contructed polygonGate gt[[1]] # }