edgardomortiz / vcf2phylip

Convert SNPs in VCF format to PHYLIP, NEXUS, binary NEXUS, or FASTA alignments for phylogenetic analysis
GNU General Public License v3.0
294 stars 85 forks source link

All SNPs were removed by vcf2phylip #46

Closed paul1000ton-coder closed 11 months ago

paul1000ton-coder commented 11 months ago

Hello, I am trying to go from vcf file to Phylip file but it is not possible. I get this notice telling me that all my SNPs have been removed.

python3 vcf2phylip.py -i unido2.vcf -o prueb2.phylip -o muestra_03_sort.bam -m 4

Converting file unido2.vcf:

Number of samples in VCF: 6
Total of genotypes processed: 9305
Genotypes excluded because they exceeded the amount of missing data allowed: 9305
Genotypes that passed missing data filter but were excluded for not being SNPs: 0
SNPs that passed the filters: 0

Outgroup, muestra_03_sort.bam, added to the matrix(ces).
Sample 1 of 6, muestra_01_sort.bam, added to the nucleotide matrix(ces).
Sample 2 of 6, muestra_02_sort.bam, added to the nucleotide matrix(ces).
Sample 4 of 6, muestra_04_sort.bam, added to the nucleotide matrix(ces).
Sample 5 of 6, muestra_05_sort.bam, added to the nucleotide matrix(ces).
Sample 6 of 6, muestra_06_sort.bam, added to the nucleotide matrix(ces).

Done!

I did a manual inspection of the vcf file and I know that there are SNPs that are found in common in the 6 samples. Could you help me with this error please?

P.S. This is my file: unido2.txt

I used it in .vcf but it doesn't allow me to upload it in that format.

paul1000ton-coder commented 11 months ago

Update: I already fixed it using version 2.8.

Now I have another problem. With version 2.0 it recognized all my samples (I joined them using cat command in my Snippy .vcf files). But with version 2.8 it used the same file and I recognized them as if it were a single sample.

paul1000ton-coder commented 11 months ago

I had a very productive hours. You can solve it. I used "bcftools merge" to "horizontally" merge the vcf files from Snippy.

vcf2phylip is an amazing tool, it helped me a lot. Thanks!

edgardomortiz commented 11 months ago

Hi! thanks for the nice comments and I'm glad you solve the problem

Edgardo