Yes I know, question is >4 years old, but in case anyone reads this: there is the -w option in bam-readcount, which specifies how many of these warnings are emitted. Set to 0 or 1 and be done with it.
Hi I'm using bam-readcount to get coverage per nucleotide as part of our exome-seq variant annotation pipeline, following bwa and gatk when i run bam-readcount, i get the following error for each position: "Couldn't grab single-end mapping quality for read HWUSI-EAS753:41:FC:4:79:2401:16705. Check to see if SM tag is in BAM" Is there a way to overcome this error?
Thanks
3 answers
This error message has to do with the SM tags on the read which is the single-ended mapping quality. Some aligners do not report this so bam-readcount reports this warning when it cannot grab the value. It does not invalidate your results and you can safely ignore this error, but you should not use the single ended mapping quality field of the output.
If I remember correctly, this is a warning, not an error. If you're simply looking for read counts and don't care about the mapping qualities, you're all right.
Edit: I got it right, but ernfrid's should be treated as canonical - he wrote the tool :)
The SM tag in question is not the read-group "Sample" tag in the header. This warning is about the SM tag indicating "Template-independent mapping quality" which is an integer value per read alignment.
Log in to answer this question.