Description Usage Arguments Details Value Author(s) See Also Examples
This function performs differential expression analysis for singel-cell RNA-seq data in two phases: phase transition (probability of being expressed), and magnitude tuning (levels of expression once the gene is on). Currently the function only works for the comparison of two biological conditions.
1 | twoPhaseDE(sc2p.obj, design, test.which, low.prob = 0.99, offset = c("SC2P", "sf"))
|
sc2p.obj |
An object of sc2pSet. Should be the result object from 'eset2Phase' function. |
design |
A character vector of variable names in pData(sc2p.obj) to provide regression covariates in DE test. |
test.which |
An integer for the index of the to-be-tested binary variable in argument 'design'. |
low.prob |
xxxxxxxxxxxxxx What's this??? |
offset |
Indicates the method to compute normalization factor. 'SC2P' is the normalization procedure provided by SC2P. 'sf' uses the total counts in cells as normalizing constant. |
est2Phase needs to be called before this function to estimate the probabilities of being in two states.
A data frame with following columns:
p1 |
|
p2 |
|
Ph1.coef |
|
Ph1.pval |
|
m1 |
|
m2 |
|
Ph2.coef |
|
Ph2.ci.lo |
|
Ph2.ci.hi |
|
Ph2.pval |
|
logFC |
Log fold change |
The data frame is sorted by gene names alphabetically.
Zhijin (Jean) Wu <zwu@stat.brown.edu>
est2Phase, topGene, visGene
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | ## Not run:
data(brain_scRNAseq)
## create ExpressionSet
colnames(Y) <- rownames(design)
phenoData <- new("AnnotatedDataFrame", data=design)
eset <- ExpressionSet(assayData=Y, phenoData=phenoData)
## estimate phases
data <- eset2Phase(eset)
data
## DE test
de.sc2p <- twoPhaseDE(data, design="celltype", test.which=1, offset="sf")
## list top ranked DE genes
topGene(de.sc2p, phase=1)
topGene(de.sc2p, phase=2)
topGene(de.sc2p, phase="both")
## visualize top DE gene in phase 2
visGene(topGene(de.sc2p, 2)$Gene.name[1], data, group.name="celltype")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.