If I execute "AddOrReplaceReadGroups" on a sorted and duplicate-marked .bam file, do I have to re-sort and re-mark duplicates?
0
0
Entering edit mode
17 months ago
javiflaja ▴ 50

I'm brand new in Bioinformatics, and building my first variant calling pipeline for human genomes. Now, I got stuck using BaseRecalibrator as it needs read groups in my .bam file, so I took my sorted_dedup_output.bam and ran Picard AddOrReplaceReadGroups.

Is it necessary for me to reapply a sorting and duplicate marking step? Thanks in advance! Very helpful community!

picard AddOrReplaceReadGroups bam read-groups • 959 views
ADD COMMENT
1
Entering edit mode

1) read groups should have been specified from the start (eg. with bwa mem -R )

2) if you do'nt specify SORT_ORDER, the order is the same https://github.com/broadinstitute/picard/blob/master/src/main/java/picard/sam/AddOrReplaceReadGroups.java#L175 , so you don't need to re-sort.

ADD REPLY
0
Entering edit mode

1) I realised I was supposed to add RGs during alingment command only after I was long done with that step. But I imgined the tool "addorreplacereagroups" could be useful after, if not, what's the use of it right? 2) how about Mark-Dup?

ADD REPLY

Login before adding your answer.

Traffic: 2106 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6