How to fix .bam file that was diagnosed as "MISSING_READ_GROUP" by Picard ValidateSamFile
1
0
Entering edit mode
Michal ▴ 10
@89e09f79
Last seen 2.8 years ago
Israel

Hi everyone,

I used bwa to index my reference genome: bwa index ref_genome.fna.gz

I used bwa mem command on my paired end genome assembly:

the command: bwa mem -t 10 ref_genome.fna.gz FISH_DATA/Individuals/F1/F1_1.fq.gz /FISH_DATA/Individuals/F1/F1_2.fq.gz > f1_map2ref.sam

convert sam to bam: samtools view -S -b -t 10 f1_map2ref.sam > f1_map2ref.bam

then I sorted: samtools sort -o f1_map2ref.sorted.bam f1_map2ref.bam

then I used picard ValidateSamFile on the output (after mapping my assembly to the ref genome convert to bam and sort)

the command:

java -jar picard.jar ValidateSamFile \ -I f1_map2ref.sorted.bam -MODE SUMMARY

The results: ## HISTOGRAM java.lang.String Error Type Count ERROR:MISSING_READ_GROUP 1 WARNING:RECORD_MISSING_READ_GROUP 499577401

I would be very grateful if anyone would help me understand how to fix the problem

Picard ValidateSamFile MISSING_READ_GROUP • 1.8k views
ADD COMMENT
0
Entering edit mode
Kevin Blighe ★ 3.9k
@kevin
Last seen 11 days ago
Republic of Ireland

Hi Michal, this question is not related to any R / Bioconductor package; therefore, you should instead post it at Biostars or Bioinformatics Stack Exchange.

Thanks,

Kevin

PS - you can probably solve the issue by adding a read group to your BAM file. Please take a look at: https://gatk.broadinstitute.org/hc/en-us/articles/360037226472-AddOrReplaceReadGroups-Picard-

Either that, or you can add the read group during alignment via the -R command line parameter that is passed to bwa mem:

-R STR        read group header line such as '@RG\tID:foo\tSM:bar' [null]
ADD COMMENT
1
Entering edit mode

Thank you very much! I will do so

ADD REPLY

Login before adding your answer.

Traffic: 682 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