knitr::opts_chunk$set( collapse = TRUE, comment = "#>", fig.path = "man/figures/README-", out.width = "100%" )
CytOpT
CytOpT
uses regularized optimal transport to directly estimate the different cell population proportions from a biological sample characterized with flow cytometry measurements.
CytOpT
is an R
package that provides a new algorithm relying regularized optimal transport to directly estimate the different cell population proportions from a biological sample characterized with flow cytometry measurements. Algorithm is based on the regularized Wasserstein metric to compare cytometry measurements from different samples, thus accounting for possible mis-alignment of a given cell population across sample (due to technical variability from the technology of measurements).
The main function of the package is CytOpT()
.
The methods implemented in this package are detailed in the following article:
Paul Freulon, Jérémie Bigot, Boris P. Hejblum. CytOpT: Optimal Transport with Domain Adaptation for Interpreting Flow Cytometry data. Annals of Applied Statistics, 17(2), 1086-1104. doi:10.1214/22-AOAS1660 https://doi.org/10.1214/22-AOAS1660 https://arxiv.org/abs/2006.09003
You can install and load CytOpT
into R
from
CRAN
with the following commands:
install.packages("CytOpT") library(CytOpT)
Alternatively, you can install the development version of CytOpT like so:
remotes::install_github("sistm/CytOpT-R") library(CytOpT)
This is a basic example of CytOpt
usage:
library(CytOpT) # Load source Data data("HIPC_Stanford")
# Define the true proportions in the target data set gold_standard_manual_prop <- c(table(HIPC_Stanford_1369_1A_labels)/length(HIPC_Stanford_1369_1A_labels))
# Run CytOpt and compare the two optimization methods res <- CytOpT(X_s = HIPC_Stanford_1228_1A, X_t = HIPC_Stanford_1369_1A, Lab_source = HIPC_Stanford_1228_1A_labels, theta_true = gold_standard_manual_prop, eps = 0.0001, lbd = 0.0001, n_iter = 10000, n_stoc=10, step_grad = 10, step = 5, power = 0.99, method='both', monitoring=TRUE)
summary(res)
plot(res)
Bland_Altman(res$proportions)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.