gatk
gatk copied to clipboard
BQSR can produce tables with missing ReadGroups
BaseRecalibrator can create a recalibration table which doesn't contain all the readgroups in the input sample. Then when ApplyBQSR is run on the same file with that table it crashes with an exception.
ex:
java.lang.IllegalStateException: The covariates table is missing ReadGroup GROUP_1 in RecalTable0
This can happen because BaseRecalibrator used a stricter set of filters than ApplyBQSR. If all the reads in a read group are filtered in BQSR then that read group will be missing from the recalibration table and fail when running ApplyBQSR. A possible example is a readgroup that only has duplicates or secondary reads.