Entering edit mode
16 months ago
Manuel Sokolov Ravasqueira
▴
110
I am applying the GATK best practices for variant calling pipeline.
By applying the picard addOrReplaceReadGroups I got the error: "invalid_mapping_quality", I read the post Final Solution For "Mapq Should Be 0 For Unmapped Read.". So decided to remove unmapped reads with samtools view -bF 4.
My question is since I will apply the GATK base recalibrator, is it better to set QC = 0 to the reads that are unmapped and how would I do this? Or removing them is the best practice?
Best Regards, Manuel
I'm not sure "Mapq Should Be 0 For Unmapped Read." will be a problem for gatk base recal as it will just ignore unampped reads.
https://github.com/broadinstitute/gatk/blob/master/src/main/java/org/broadinstitute/hellbender/engine/ReadWalker.java#L131C46-L131C66
valid start is required:
https://github.com/broadinstitute/gatk/blob/master/src/main/java/org/broadinstitute/hellbender/engine/filters/WellformedReadFilter.java#L65
Thanks! Is there any flag for ignoring this error with picard addOrReplaceReadGroups? And for example for estimating TMB from BAM files would it be a problem?
try
VALIDATION_STRINGENCY=LENIENT
I did this:
It generated the output file but still showed error. I proceded with doing the next step picard MarkDuplicates with the same flag "-VALIDATION_STRINGENCY ", error was displayed again yet it generated output? Should I keep adding this flag for the rest of the pipeline whenever use picard?