This is a test version of Biostars. For the public version, visit https://www.biostars.org.
mate_not_found ValidateSam (picardtools) error

Hi there!

I am stuck with this issue and could not find a solution on the many posts which have already been written on it.

After mapping with bwa mem (same when trying bwa aln on the same fastqs), I validate my bam files with picardtools ValidateSamFile and I got about 3% of the reads marked by a MATE_NOT_FOUND error. Already tried:

  • Fastq reads 1 and 2 are in sync.
  • Running FixMateInformation did not fix it.
  • Sorting the bam did not fix it
  • Checking the flag of these problematic reads in the bam, I could see that most of them are already flagged as "mate unmapped" (then why validateSam complains?) and only some of them are flagged as both mates are mapped.

Should I simply not care about it and go on with the downstream SNP calling (I will use FreeBayes)?

Any idea to solve or understand this issue will be very appreciated.

All the best, Emiliano

alignment bwa mapping picard

Mapping with bwa mem

$BWA mem -M -t 2 $REFNAME $i\.1.fastq $i\.2.fastq | $SAMTOOLS view -b -S -q 10 - > $i.bam

Sorting bam with samtools

$SAMTOOLS sort -@ 2 -m 2G -T $i_TEMP -o $i.sort.bam $i.bam

Validate bam with picardtools

java -jar picard.jar ValidateSamFile I=$i.sort.bam MODE=SUMMARY TMP_DIR=$OUTFOL R=$REFNAME MAX_OPEN_TEMP_FILES=500 VALIDATION_STRINGENCY=SILENT O=$i.sort.validation

Results of the validation

## HISTOGRAM    java.lang.String
Error Type  Count
ERROR:INVALID_VERSION_NUMBER    1
ERROR:MATE_NOT_FOUND    239229

0 answers

No answers yet.

Log in to answer this question.