normalise {protti} | R Documentation |
Intensity normalisation
Description
Performs normalisation on intensities. For median normalisation the normalised intensity is the original intensity minus the run median plus the global median. This is also the way it is implemented in the Spectronaut search engine.
Usage
normalise(data, sample, intensity_log2, method = "median")
Arguments
data |
a data frame containing at least sample names and intensity values. Please note that if the data frame is grouped, the normalisation will be computed by group. |
sample |
a character column in the |
intensity_log2 |
a numeric column in the |
method |
a character value specifying the method to be used for normalisation. Default is "median". |
Value
A data frame with a column called normalised_intensity_log2
containing the
normalised intensity values.
Examples
data <- data.frame(
r_file_name = c("s1", "s2", "s3", "s1", "s2", "s3"),
intensity_log2 = c(18, 19, 17, 20, 21, 19)
)
normalise(data,
sample = r_file_name,
intensity_log2 = intensity_log2,
method = "median"
)