norm2Filter-class | R Documentation |
Class and constructors for a filter
that fits a bivariate
normal distribution to a data set of paired values and selects data points
according to their standard deviation from the fitted distribution.
norm2Filter(x, y, method="covMcd", scale.factor=1, n=50000,
filterId="defaultNorm2Filter")
x, y |
Characters giving the names of the measurement parameter on which
the filter is supposed to work on. |
filterId |
An optional parameter that sets the |
scale.factor, n |
Numerics of length 1, used to set the
|
method |
Character in |
The filter fits a bivariate normal distribution to the data and selects all
events within the Mahalanobis distance multiplied by the scale.factor
argument. The constructor norm2Filter
is a convenience function for
object instantiation. Evaluating a curv2Filter
results in an object
of class logicalFilterResult
. Accordingly, norm2Filters
can be used to subset and to split flow cytometry data sets.
Returns a norm2Filter
object for use in filtering
flowFrame
s or other flow cytometry objects.
method
One of covMcd
or cov.rob
defining method used for computation of covariance matrix.
scale.factor
Numeric vector giving factor of standard
deviations used for data selection (all points within
scalefac
standard deviations are selected).
n
Object of class "numeric"
, the number of
events used to compute the covariance matrix of the bivariate
distribution.
filterId
Object of class "character"
referencing the filter.
parameters
Object of class "ANY"
describing
the parameters used to filter the flowFrame
or
flowSet
.
Class "parameterFilter"
, directly.
Class "concreteFilter"
, by class
parameterFilter
, distance 2.
Class "filter"
, by class parameterFilter
,
distance 3.
Objects can be created by calls of the form new("norm2Filter",
...)
or using the constructor norm2Filter
. The constructor
is the recommended way.
signature(x = "flowFrame", table =
"norm2Filter")
: The workhorse used to evaluate the filter on
data. This is usually not called directly by the user, but
internally by calls to the filter
methods.
signature(object = "norm2Filter")
: Print
information about the filter.
See the documentation in the flowViz
package for plotting of norm2Filters
.
F. Hahne
cov.rob
, CovMcd
,
filter
for evaluation of
norm2Filters
and split
and Subset
for
splitting and subsetting of flow cytometry data sets based on that.
library(flowCore)
## Loading example data
dat <- read.FCS(system.file("extdata","0877408774.B08",
package="flowCore"))
## Create directly. Most likely from a command line
norm2Filter("FSC-H", "SSC-H", filterId="myCurv2Filter")
## To facilitate programmatic construction we also have the following
n2f <- norm2Filter(filterId="myNorm2Filter", x=list("FSC-H", "SSC-H"),
scale.factor=2)
n2f <- norm2Filter(filterId="myNorm2Filter", x=c("FSC-H", "SSC-H"),
scale.factor=2)
## Filtering using norm2Filter
fres <- filter(dat, n2f)
fres
summary(fres)
## The result of norm2 filtering is a logical subset
Subset(dat, fres)
## We can also split, in which case we get those events in and those
## not in the gate as separate populations
split(dat, fres)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.