knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>"
)

Description

Excyte is a pipeline that allows exhaustive exploration of cytometry data. Excyte first preprocesses compensated fcs data, then performs unsuppervised clustering of selected events with PhenoGraph (Jacob H. Levine et.al; Cell, 2015) and dimensionality reduction via Umap (Leland McInnes et.al; arXiv:1802.03426). This pipeline outputs proportions of identified clusters for each input sample as well as intuitive visualizations.

Get started

In R, install Excyte via GitHub with the command

install.packages("devtools")
library(devtools)
install_github("maximemeylan/Excyte")

First run

To run the Excyte pipeline, input the directory containing compensated fcs files. Downsampling can be used to speed up the computation time, here 1000 events of each fcs are randomly sampled. Finally, we will run Excyte on avalaible channels.

library(gridExtra)
library(excyte)

#load sample data 
fcs.loc <- system.file("extdata",package="excyte")
file.location <- paste(fcs.loc, dir(fcs.loc), sep="/")

#for reproducible output
set.seed(8)

#run the pipeline
excyte_object <- run_excyte(fcs_dir = file.location[1:3],
                            downsampling = 3000,
                            channels = "with_desc",
                            downsampling_umap = 1000)

Results of the pipeline

excyte_object contains the result objects computed by the pipeline\

excyte_object$processed_fcs_obj contains the normalized intensities of each event \

excyte_object$pheno_objcontains the object from PhenoGraph clustering \

excyte_object$excyte_res$umap_obj contains the ouput from the Umap, including the 2D coordinates of each event.\

The percentage of clusters among each samples can be displayed by : excyte_object$phenograph_obj$phenograph_percentage

knitr::kable(excyte_object$phenograph_obj$phenograph_percentage[1:3,1:5])

Visualizations

Excyte propose several visualization than can be computed with the command

excyte_plots <- plot_excyte(excyte_obj = excyte_object,alpha = 0.7)

The visualizations can be displayed by querying the result object

Heatmap presenting the average intensity profile of each cluster

excyte_plots$heatmap

Umap of event intensities for selected channels

grid.arrange(grobs=excyte_plots$umap_channels[c(9,3,4,1,2,5)],ncol=2)

Umap of cluster membership

excyte_plots$umap_phenograph

Distribution of event intensities according to cluster membership

grid.arrange(grobs=excyte_plots$ridges_clusters[c(9,3,4,1,2,5)],ncol=2)

Re-run excyte on selected clusters

The pipeline can be re-run on a subset of the cluster to better characterize interesting populations Here we focus on CD3, CD4 high clusters, and investigate memory and activation markers

set.seed(8)
excyte_object$processed_fcs_obj$all_channels
markers <- excyte_object$processed_fcs_obj$all_channels[c(c(11,7,12,13,8,14)),1]

rerun_object <- rerun_excyte(excyte_obj = excyte_object,
                             clusters_id = c("C_19","C_12","C_18","C_13","C_05","C_08"), 
                             channels = markers,)
rerun_plots <- plot_excyte(excyte_obj = rerun_object,alpha = 1)
grid.arrange(grobs=rerun_plots$umap_channels,ncol=2)

Umap of cluster membership

rerun_plots$umap_phenograph


maximemeylan/Excyte documentation built on Nov. 10, 2020, 9:06 p.m.