Class SingleCellDescriptive
java.lang.Object
ubic.gemma.core.analysis.singleCell.SingleCellDescriptive
Descriptive statistics for single cell data.
The utilities here extend DataVectorDescriptive
by providing per-assay statistics.
- Author:
- poirigui
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic int[]
count
(SingleCellExpressionDataVector vector) Count the number of values in each assay.static int[]
countAboveThreshold
(SingleCellExpressionDataVector vector, double threshold) Compute the number of cells expressed strictly above the given threshold.static int[]
Quickly count the non-zeroes for each assay.static int
countFast
(SingleCellExpressionDataVector vector, int sampleIndex) static int
countFast
(SingleCellExpressionDataVector vector, int sampleIndex, CellLevelCharacteristics cellLevelCharacteristics, int row) static int[]
countFast
(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics) static int[]
countFastWithUnknown
(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics) static double[]
max
(SingleCellExpressionDataVector vector) static double
max
(SingleCellExpressionDataVector vector, int sampleIndex) static double
max
(SingleCellExpressionDataVector vector, int sampleIndex, CellLevelCharacteristics cellLevelCharacteristics, int row) static double[]
max
(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics) static double[]
mean
(SingleCellExpressionDataVector vector) Calculate the mean of each assay for a given vector.static double
mean
(SingleCellExpressionDataVector vector, int sampleIndex) static double
mean
(SingleCellExpressionDataVector vector, int sampleIndex, CellLevelCharacteristics cellLevelCharacteristics, int row) static double
mean
(SingleCellExpressionDataVector vector, BioAssay sample) Calculate the mean of a given assay.static double[]
median
(SingleCellExpressionDataVector vector) Calculate the median of each assay for a given vector.static double
median
(SingleCellExpressionDataVector vector, int column) static double
median
(SingleCellExpressionDataVector vector, int column, CellLevelCharacteristics cellLevelCharacteristics, int row) static double[]
min
(SingleCellExpressionDataVector vector) static double
min
(SingleCellExpressionDataVector vector, int sampleIndex) static double
min
(SingleCellExpressionDataVector vector, int sampleIndex, CellLevelCharacteristics cellLevelCharacteristics, int row) static double[]
min
(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics) static double[]
quantile
(SingleCellExpressionDataVector vector, double q) static double
quantile
(SingleCellExpressionDataVector vector, int sampleIndex, double v) static double
quantile
(SingleCellExpressionDataVector vector, int sampleIndex, CellLevelCharacteristics cellLevelCharacteristics, int row, double q) static double[]
quantile
(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics, int row, double q) static double[]
static double
sampleStandardDeviation
(SingleCellExpressionDataVector vector, BioAssay sample) static double[]
static double
sampleVariance
(SingleCellExpressionDataVector vector, BioAssay sample) Calculate the variance of a given assay.static double[]
sum
(SingleCellExpressionDataVector vector) static double[]
sum
(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics) static double[]
static double[]
sumWithUnknown
(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics)
-
Constructor Details
-
SingleCellDescriptive
public SingleCellDescriptive()
-
-
Method Details
-
max
-
max
-
max
public static double[] max(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics) -
max
public static double max(SingleCellExpressionDataVector vector, int sampleIndex, CellLevelCharacteristics cellLevelCharacteristics, int row) -
min
-
min
-
min
public static double[] min(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics) -
min
public static double min(SingleCellExpressionDataVector vector, int sampleIndex, CellLevelCharacteristics cellLevelCharacteristics, int row) -
count
Count the number of values in each assay.Missing values are not counted.
-
countFast
Quickly count the non-zeroes for each assay.Note: this is not accurate if the single-cell vector contains
NaN
s or actual zeroes or missing values as perQuantitationTypeUtils.getDefaultCountValueAsDouble(QuantitationType)
}. -
countFast
-
countFast
public static int countFast(SingleCellExpressionDataVector vector, int sampleIndex, CellLevelCharacteristics cellLevelCharacteristics, int row) -
countFast
public static int[] countFast(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics) -
countFastWithUnknown
public static int[] countFastWithUnknown(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics) -
countAboveThreshold
Compute the number of cells expressed strictly above the given threshold.- Parameters:
threshold
- a threshold value, assumed to be in theScaleType
of the vector
-
sum
-
sum
public static double[] sum(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics) -
sumWithUnknown
public static double[] sumWithUnknown(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics) -
sumUnscaled
-
mean
Calculate the mean of each assay for a given vector. -
mean
Calculate the mean of a given assay. -
mean
-
mean
public static double mean(SingleCellExpressionDataVector vector, int sampleIndex, CellLevelCharacteristics cellLevelCharacteristics, int row) -
median
Calculate the median of each assay for a given vector. -
median
-
median
public static double median(SingleCellExpressionDataVector vector, int column, CellLevelCharacteristics cellLevelCharacteristics, int row) -
quantile
-
quantile
-
quantile
public static double[] quantile(SingleCellExpressionDataVector vector, CellLevelCharacteristics cellLevelCharacteristics, int row, double q) -
quantile
public static double quantile(SingleCellExpressionDataVector vector, int sampleIndex, CellLevelCharacteristics cellLevelCharacteristics, int row, double q) -
sampleStandardDeviation
-
sampleStandardDeviation
public static double sampleStandardDeviation(SingleCellExpressionDataVector vector, BioAssay sample) -
sampleVariance
-
sampleVariance
Calculate the variance of a given assay.
-