Comparision of two VCF file with vcftools. Chromosome order error message
1
0
Entering edit mode
7.2 years ago
cmonat • 0

Hi,

I'm using the vcftools for the first time. I'm trying to compare two VCF files with the following command line:

vcftools --vcf Sample_All.vcf --diff Sample_indA.vcf --diff-site --out Multiple_vs_indA

and I get the following error message:

Error: Both files must be sorted in the same chromosomal order.
chr1 in file 2 appears to be out of order.

But I know that in both VCF file I have the chr1 included, so, why do I have this message? Plus I have tried to had the --not-chr chr1 parameter to my command line, as I understand it was advised to do in this case, but then I have the same error message but on chr2 ... Is it normal? What should I do to resolve this issue? Or maybe it is just a warning message?

Thank you

C.

vcftools VCF • 3.4k views
ADD COMMENT
0
Entering edit mode

show us the output of:

grep -v "#" Sample_All.vcf | cut -f 1 | uniq | tr "\n" " "

and

grep -v "#" Sample_indA.vcf | cut -f 1 | uniq | tr "\n" " "
ADD REPLY
0
Entering edit mode
7.1 years ago
cmonat • 0

Hi,

I assume the output of these two commands should be the same, right? I have tried to sort my files, and now it seems to work.

Many thanks!

C.

ADD COMMENT

Login before adding your answer.

Traffic: 1649 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6