Extracting haplotypes from phased vcf file
1
2
Entering edit mode
5.9 years ago
siddazra ▴ 20

I have a phased genotype VCF file(i.e haplotype in vcf format). I am interested only in the haplotypes that are there in phased vcf file. Please help or suggest some other way to do it.

haplotype • 7.6k views
ADD COMMENT
0
Entering edit mode

what kind of output do you need ?

ADD REPLY
0
Entering edit mode

I want it in standard haplotype format (.hap)

ADD REPLY
3
Entering edit mode
5.9 years ago

Hello siddazra,

does bcftools convert with the --hapsample option do what you want?

Other solution is mention in this thread.

fin swimmer

ADD COMMENT
1
Entering edit mode

It worked. I used the command

bcftools convert --hapsample --vcf-ids file.vcf -o output

Thanks.

ADD REPLY
0
Entering edit mode

Fine :)

I moved my comment to an answer, so you can mark it as accepted.

fin swimmer

ADD REPLY

Login before adding your answer.

Traffic: 1789 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