View source: R/negative_binomial_check.R
goodness_of_fit_DESeq2 | R Documentation |
This function calculates goodness-of-fit pvalues for all genes by looking at how the NB model by DESeq2 fit the data
goodness_of_fit_DESeq2(
se,
count_matrix,
condition,
other_variables = NULL,
num_genes = 500,
seeding = 13
)
se |
the se object where all the data is contained |
count_matrix |
name of the assay with gene expression matrix (in counts) |
condition |
name of the se colData with the condition status |
other_variables |
name of the se colData containing other variables of interest that should be considered in the DESeq2 model |
num_genes |
downsample value, default is 500 (or all genes if less) |
seeding |
integer to set the seed to for reproducibility; default is 13 |
a matrix of pvalues where each row is a gene and each column is a level within the condition of interest
# example code
library(scran)
se <- mockSCE(ncells = 20)
se$Treatment <- as.factor(se$Treatment)
se$Mutation_Status <- as.factor(se$Mutation_Status)
nb_results <- goodness_of_fit_DESeq2(se = se, count_matrix = "counts",
condition = "Treatment", other_variables = "Mutation_Status")
nb_results[1]
nb_results[2]
nb_results[3]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.