Hi everyone! Huge thanks to all the developers and...
# riboseq
j
Hi everyone! Huge thanks to all the developers and maintainers of nfcore-riboseq. It's really nice to see such a useful pipeline. I have a very basic question - does UMI-tools extract run before TrimGalore, or the other way around? The pipeline overview at https://nf-co.re/riboseq/1.1.0/ shows UMI-tools running after TrimGalore, but the written description says the opposite. I'm not 100% sure I'm interpreting the running processes right, but NFCORE_RIBOSEQRIBOSEQFASTQ_QC_TRIM_FILTER_SETSTRANDEDNESSFASTQ FASTQC UMITOOLS TRIMGALOREUMITOOLS_EXTRACT seems to be running before NFCORE_RIBOSEQRIBOSEQFASTQ_QC_TRIM_FILTER_SETSTRANDEDNESSFASTQ FASTQC UMITOOLS TRIMGALORETRIMGALORE I'm asking this because my reads have the structure Adapter-UMI-RFP-UMI-Adapter, so it would be important for me that TrimGalore runs first. Thanks in advance!
j
Hi @Jia Xuan Leong, Apologies for the delay in looking into this but you appear to be correct and I believe the order we have it is incorrect for the vast vast majority of read architectures. This part of the workflow was actually inherited from the very established #CE8SSJV3N workflow so I question how much of an impact the order of operations has as surely this would have been identified as an issue by now. @Felix Krueger @Jonathan Manning if either of you get a minute could you weigh in with yer expert opinions?
i
I’ll jump in if that’s ok. Extracting UMIs before adapter trimming is generally the more flexible and recommended workflow (Extracting UMIs first isolates and protects the UMI from any downstream processing). Because specifying barcode patterns with UMI-tools is very flexible, in this instance (with your library design @Jia Xuan Leong) you just need to ensure you correctly specify
—bc-pattern
and
—bc-pattern2
in an adaptor-aware way i.e. reflecting the length and position of your adaptors in each read. This can be done with either string or regex pattern definition: the aim is extract just the UMIs, leaving the adaptors still in the read. Next, TrimGalore will remove the adapters. Have a look at umitools docs and potentially test with a small subsample of your reads to check the settings. Indeed in the tube map the order is wrong - one for the next release?
j
Thank you Ira! I learn something new every day. I dont think I have ever used UMI-tools to its full potential
🙂 1
🙏 1
j
Ahh I see, thanks a lot Ira! Indeed I didn't know you can use UMI-tools that way.
j
Indeed in the tube map the order is wrong - one for the next release?
I have an allergy to tube maps, would appreciate a PR 😉
(also apologies, just back from leave to day, thank you @Ira Iosub for resolving this)
j
We should definitely at least make an issue. @Jia Xuan Leong would you have time to do this?
j
Yes sure, I'll do that!
🙏 2