This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Input Error Using Varscan2.3

Hi,

I'm using Varscan2.3 to generate vcf files. I understand that we need to convert the BAM files to mpileup format first and then give it as an input. But I keep getting an error.

The command I used:

samtools mpileup -f ~/refs/human_g1k_v37.fasta file.bam | java -jar /varscan/VarScan.v2.3 mpileup2snp --output-vcf > raw.vcf

I get the following error:

Error: Invalid format for pileup at line 12
1       11829   A       0

There was a thread already (Varscan Error On Mpileup Input), but that didn't help me. Does anyone know how to resolve this?

Thanks!

error mpileup

Hi, I wonder if you have solved the problem, if so, would you mind giving me some suggestions on how to solve this?

I did actually. I don't remember the exact command but, what I did was instead of piping it, I created mpileup's for both tumor and normal first. And then I used this command on the mpileup's

java -jar VarScan.jar somatic normal.pileup tumor.pileup --mpileup 1

This gives you the somatic variants directly.

2 answers

This is an issue due to the zero-depth lines reported by SAMtools mpileup, which VarScan does not expect, and should be fixed in v2.3.6. Please let me know if it's still an issue!

I resolved the problem, but this is something you might want to know.

I tried the samtools mpileup and pipe to Varscan.

It did not work when I used samtools 0.1.19 for Varscan2.2.11 ,Varscan2.3.5 and Varscan2.3.6.

But if I use the samtools 0.1.18, all versions worked.

Conclusion: the newer version of samtools may cause the problem.

Try using pileup2snp instead of mpileup2snp (even if you use mpileup to build the pileup). This usually works for me.

Log in to answer this question.