Learn R Programming

DRIMSeq (version 1.0.2)

dmTest: Likelihood ratio test

Description

First, estimate the null Dirichlet-multinomial model proportions, i.e., feature ratios are estimated based on pooled (no grouping into conditions) counts. Use the likelihood ratio statistic to test for the difference between feature proportions in different groups to identify the differentially spliced genes (differential splicing analysis) or the sQTLs (sQTL analysis).

Usage

dmTest(x, ...)
"dmTest"(x, compared_groups = levels(samples(x)$group), prop_mode = "constrOptimG", prop_tol = 1e-12, verbose = 0, BPPARAM = BiocParallel::MulticoreParam(workers = 1))
"dmTest"(x, prop_mode = "constrOptimG", prop_tol = 1e-12, verbose = 0, BPPARAM = BiocParallel::MulticoreParam(workers = 1))

Arguments

x
dmDSfit or dmSQTLfit object.
...
Other parameters that can be defined by methods using this generic.
compared_groups
Vector that defines which experimental conditions should be tested for differential splicing. By default, we test for a difference between any of the groups specified in samples(x)$group. Values in this vector should indicate levels or numbers of levels in samples(x)$group.
prop_mode
Optimization method used to estimate proportions. Possible values "constrOptim" and "constrOptimG".
prop_tol
The desired accuracy when estimating proportions.
verbose
Numeric. Definie the level of progress messages displayed. 0 - no messages, 1 - main messages, 2 - message for every gene fitting.
BPPARAM
Parallelization method used by bplapply.

Value

Returns a dmDStest or dmSQTLtest object.

See Also

data_dmDSdata, data_dmSQTLdata, plotTest, dmDispersion, dmFit

Examples

Run this code

###################################
### Differential splicing analysis
###################################
# If possible, use BPPARAM = BiocParallel::MulticoreParam() with more workers

d <- data_dmDSdata

### Filtering
# Check what is the minimal number of replicates per condition 
table(samples(d)$group)
d <- dmFilter(d, min_samps_gene_expr = 7, min_samps_feature_expr = 3, 
 min_samps_feature_prop = 0)

### Calculate dispersion
d <- dmDispersion(d, BPPARAM = BiocParallel::SerialParam())

### Fit full model proportions
d <- dmFit(d, BPPARAM = BiocParallel::SerialParam())

### Fit null model proportions and test for DS
d <- dmTest(d, BPPARAM = BiocParallel::SerialParam())
plotTest(d)

head(proportions(d))
head(statistics(d))
head(results(d))



Run the code above in your browser using DataLab