How to choose vcf-compare options
1
1
Entering edit mode
8.1 years ago
Chenglin ▴ 230

Thanks to the help from experts from this forum, I have already compressed and indexed the vcf files to provide inputs for using vcf-compare. I want to know the variants between two accessions. I tried -p option to generate Venn diagrams but it didn't work. To compare genotypes (not only positions), I tried -g option, it seemed not working either. Any suggestions?

SNP • 8.1k views
5
Entering edit mode
8.1 years ago

vcf files must be bgzip compressed and tabix indexed. having said that:

vcf-compare *.vcf.gz will output some summary stats

vcf-compare -g *.vcf.gz will output the previous summary stats plus genotype stats (summary, proper comparison, allele frequency and depth)

vcf-compare -p prefix *.vcf.gz will plot these stats, generating prefix*.gp and prefix*png files

you can also use the faster htslib implementation of bcftools instead of vcftools, using bcftools stats and plot-vcfstats.

0
Entering edit mode

Thank you very much for your detailed explain. I will try.