Description Usage Arguments Value Examples
This is a custom implementation of the algorithm described by Newman et al (Nautre Methods 12:453-457). CIBERSORT is an algorithm for estimating the cell type composition of a bulk sample, given a gene expression profile of the sample and a known gene expression profile for each cell type potentially contributing to the sample.
1 2 3 4 |
exprs |
A data frame or matrix of raw read counts of \epmhbulk RNA-seq samples. Column names correspond to sample names, row names to genes. |
base |
A matrix of read counts representing the gene expression profiles of all cell types that might contribute to the bulk samples. See examples below for how to generate this object from an object of class |
design |
A named vector assigning sample names to sample class, see examples below. |
markergenes |
A vector of genes to be included in the analysis, defaults to |
nu |
Different values of nu to evaluate support vector regression at, see |
optim.nu |
In the original CIBERSORT implementation, SVR is evaluated at several values of nu and the value with the best RSME is chosen. This can lead to overfitting. If |
mc.cores |
Number of cores used, e.g. for the parallel evaluation at different balues of nu. |
... |
Parameters passed to |
A data frame in long format suitable for plotting with ggplot2.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | ## Not run:
#See also package vignette CIBERORT.Rmd
#1. identify marker genes from a seurat object
NicheMarkers10x <- FindAllMarkers(NicheData10x, test.use = "roc")
usegenes <- unique(NicheMarkers10x$gene[(NicheMarkers10x$myAUC > 0.8 |NicheMarkers10x$myAUC < 0.2) ])
#2. compute mean expression per cell type
mean_by_cluster <- do.call(cbind, lapply(unique(NicheData10x@ident), function(x) {
apply(NicheData10x@raw.data[usegenes,NicheData10x@cell.names][,NicheData10x@ident == x], 1,mean )
}))
colnames(mean_by_cluster) <- unique(NicheData10x@ident)
#3. Create a vector that maps samples to biological class
LCM_design <- NicheMetaDataLCM$biological.class
names(LCM_design) <- NicheMetaDataLCM$id
4. Run CIBERSORT
CIBER <- runCIBERSORT(NicheDataLCM, mean_by_cluster,usegenes, LCM_design, mc.cores=3)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.