impute_na | R Documentation |
Impute missing values in a LipidomicsExperiment
impute_na(
data,
measure = "Area",
method = c("knn", "svd", "mle", "QRILC", "minDet", "minProb", "zero"),
...
)
data |
LipidomicsExperiment object. |
measure |
Which measure to use as intensity, usually Area,
Area Normalized or Height. Default is |
method |
The imputation method to use. All methods are wrappers for
|
... |
Other arguments passed to the imputation method. |
LipidomicsExperiment object with missing values imputed.
data(data_normalized)
# Replace with values calculated using K-nearest neighbors
impute_na(data_normalized, "Area", "knn", 10)
# Replace with values calculated from the first K principal components
impute_na(data_normalized, "Area", "svd", 3)
# Replace with Maximum likelihood estimates
impute_na(data_normalized, "Area", "mle")
# Replace with randomly drawn values from a truncated distribution
impute_na(data_normalized, "Area", "QRILC")
# Replace with a minimal value
impute_na(data_normalized, "Area", "minDet")
# Replace with randomly drawn values from a Gaussian distribution
# cerntered around a minimal value
impute_na(data_normalized, "Area", "minProb")
# Replace with zero (not recommended)
impute_na(data_normalized, "Area", "zero")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.