TCP-Lab / transportome_profiler

Code to profile the expression of the transportome
GNU General Public License v3.0
0 stars 0 forks source link

The Log Fold Change calculation is wrong #23

Closed MrHedmad closed 9 months ago

MrHedmad commented 12 months ago

In the following snippet, we see that the Log Fold Change is calculated just from a call to DESeq:

https://github.com/TCP-Lab/transportome_profiler/blob/70950ec4facc379abc919c11ae7cff6fd66c872d/src/modules/run_dea/run_deseq.R#L78-L104

The LFC calculated this way is unshrinked, since 6 years ago DESeq2 no longer shrinks LFCs automatically. See here and here for relevant conversations. Coincidentally, high sample sizes makes the shrinkage to not be relevant, so we would not have encountered the issue here. The problem would have arisen later, though.

In any case, the pipeline is wrong.

The issue also ties to #22, since editing this code might make everything faster as a result.