Thank you, Gordon. This is good enough!
I have a RNAseq dataset where I'm interested in seeing if a target gene genetically modified is upregulated (one-sided hypothesis), but at the same time, I want to assess the possible off-targets (also one-sided). I'm trying to formulate this through a Bayesian perspective for which I can provide priors to my expected target gene and predicted off-targets (based on scores from another tool independent of gene expression levels).
So, for every gene in the dataset, I will have something like this:

In a bayesian regression setting, I think the priors would be the log2FC, like 10, 2, 2, 0, ...
Is there a way to implement this with common workflows, like DESeq2, limma, or EdgeR? I'm open to new suggestions. Many thanks
1 answer
Do I understand correctly that you have the prior probability of DE for each individual gene and want to incorporate that into the DE analysis? It is possible to do so using output from the limma package.
Let PriorProbDE be the vector of genewise prior probabilities of the same length as the number of genes. You can run a limma analysis with
Overall <- mean(PriorProbDE)
fit <- eBayes(fit, proportion=Overall)
Then
LogPosteriorOddsDE <- fit$lods - qlogis(Overall) + qlogis(PriorProbDE)
is the log posterior odds of DE. The posterior probability of DE is
PosteriorProbDE <- plogis(LogPosteriorOddsDE)
This analysis is for two-sided tests. If you want to do one-sided tests, then the prior must be specified in a more sophisticated way rather than simply as a prior probability of DE.
Log in to answer this question.