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.
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.