Description Usage Arguments Value Author(s) See Also Examples
This function is used to detect differentially expressed genes between two specified groups of cells in a raw read counts matrix of single-cell RNA-seq (scRNA-seq) data. It takes a non-negative integer matrix of scRNA-seq raw read counts object as input. So users should map the reads (obtained from sequencing libraries of the samples) to the corresponding genome and count the reads mapped to each gene according to the gene annotation to get the raw read counts matrix in advance.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | SwarnSeqLRT(
CountData,
RNAspike.use,
CE.range,
spikes,
spike.conc,
parallel,
norm.method,
group,
CellCluster,
CellAuxil,
maxit,
eps,
muoffset,
phioffset,
weights,
p.adjust.method
)
|
CountData |
Observed count data matrix for genes, rows represent genes, columns represent cells. |
RNAspike.use |
Logical value indicating TRUE/FALSE, if TRUE, spikes and spike.conc information must be provided. |
CE.range |
Two-element vector representing the lower and upper limits for the estimated range of capture efficiencies
(ONLY needed if RNAspike.use = |
spikes |
Observed count matrix for spike-in transcripts, rows represent spike-in transcripts, columns represent cells. Only needed if RNAspike.use = |
spike.conc |
Vector of theoretical count for each spike-in transcript in one cell (ONLY needed if RNAspike.use = |
parallel |
If FALSE (default), no parallel computation is used; if TRUE, parallel computation is performed. |
norm.method |
Method for normalizing the scRNA-seq count expression data, either 'DESeq2' (maximum likelihood, Ye et al., 2017) or 'TMM' (Robinson et al., 2010). |
group |
Vector which specifies the membership of the cells, i.e. two groups to be compared, corresponding to the columns in the count data matrix. |
CellCluster |
Vector which specifies the cluster memberships of the cells, i.e. each entry represents memberships of the columns of the count data matrix. |
CellAuxil |
Vector of cell level auxiliary information, corresponding to the columns in the counts matrix, default is NULL. |
maxit |
Maximum number of iterations for Expected-Maximization (EM) algorithm. |
eps |
Convergennce criteria for EM algorithm. |
muoffset |
Offset parameter for mean (mu) parameter, default is NULL. |
phioffset |
Offset parameter for zero inflation (phi) parameter, default is NULL. |
weights |
Observation wise weights for the cells, default is unity vector. |
p.adjust.method |
Logical variable represents the method used for multiple hypothesis correction. It can be any value from ("holm", "hochberg", "hommel", "bonferroni", "BH", "BY"). |
A data frame containing the results from differential expression analysis, rows are genes and columns contain the following items:
1 totalMean_1, totalMean_2, Adj_Mean_1, Adj_Mean_2, AdjNormMean_1, AdjNormMean_2 are the total mean, adjusted (capture efficiency) mean, normalized mean for cellular groups 1 and 2 respectively.
2 FoldChange, log2FC, AdjNormFC, log2AdjNormFC are the fold change, log fold change, and log normalized fold change for the genes respectively.
3 Stat.DE, Pval.DE, DE.Adj.pval, and DE.FDR are values of DE statistic, p-value, adjusted p-value, false discovery rate, obtained from DE analysis, for the genes.
4 Stat.DZI, Pval.DZI, DZI.Adj.pval, DZI.FDR are Differential Zero Inflation (DZI) statistic, DZI p-value, DZI adjusted p-value, DZI false discovery rate results obtained for each gene from DZI analysis.
Samarendra Das
TestData
, a test dataset for SwarnSeq.
dzinb
, dzinb funcion in SwarnSeq.
ZINBEM
, Expected-Maximization (EM) algorithm for ZINB model in SwarnSeq.
SwarnSeq
, SwarnSeq function in SwarnSeq.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | #Load the test count data, spike-in counts and spike-in concentration data for SwarnSeq.
data(TestData)
counts <- TestData$CountData
Spikes <- TestData$SpikeCounts
SpikeConc <- TestData$SpikeConc
#specifying the group information, the group 1 and 2 have two hundred cells each.
group <- c(rep(1, 200), rep(2, 200))
#Specifying the cluster memberships of the cells in columns of countData.
cellcluster <- c(rep(1, 60), rep(2, 40), rep(3, 50),
rep(4, 50), rep(5, 30),
rep(6, 90),
rep(7, 80))
#Do not run
#parameters from EM algorithm for each gene.
#results <- SwarnSeqLRT(CountData=counts, RNAspike.use=TRUE, spikes=Spikes, spike.conc=SpikeConc,
#parallel=FALSE, norm.method="TMM", group=group, CellCluster=cellcluster,
#CellAuxil=NULL, maxit=500, eps=1e-10,
#muoffset=NULL, phioffset=NULL, weights=NULL, p.adjust.method="hochberg")
#When Spike-in information not available.
#results <- SwarnSeqLRT(CountData=counts, RNAspike.use=FALSE, CE.range=c(0.1, 0.4)
#parallel=FALSE, norm.method="TMM", group=group, CellCluster=cellcluster,
#CellAuxil=NULL, maxit=500, eps=1e-10,
#muoffset=NULL, phioffset=NULL, weights=NULL, p.adjust.method ="hochberg")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.