computeMedianCV {scp} | R Documentation |
The function computes for each cell the median CV. The expression data is normalized twice. First, cell median expression is used as normalization factor, then, the mean for each batch and peptide. The CV is then computed for each protein in each cell. CV is the standard deviation divided by the mean expression. The CV is computed only if there are more than 5 observations per protein per cell.
computeMedianCV(object, i, peptideCol, proteinCol, batchCol)
object |
A |
i |
A |
peptideCol |
A |
proteinCol |
A |
batchCol |
A |
A new columns, .medianCV
, is added to the colData
of the assay
i
and contains the computed median CVs.
Watch out that peptideCol
and proteinCol
are feature
variables and hence taken from the rowData
. batchCol
is a
sample variable and is taken from the colData
of the QFeatures
object.
A QFeatures
object.
data("scp1") scp1 <- computeMedianCV(scp1, i = "peptides", proteinCol = "protein", peptideCol = "peptide", batchCol = "Set") ## Check results hist(scp1[["peptides"]]$.MedianCV)