Converting VCF to BEAGLE format
1
0
Entering edit mode
8 months ago
diversitree ▴ 10

Can bcftools generate a beagle formatted file from a vcf with genotype likelihoods? If so, how could I do this? I'm not seeing any documentation on this. vcftools has the ability to do so but I want to know if bcftools can do this and how. Thanks!

bcftools variant snp beagle vcf • 1.3k views
ADD COMMENT
0
Entering edit mode
8 months ago
zx8754 12k

Try vcftools

--BEAGLE-GL
--BEAGLE-PL

These options output genotype likelihood information for input into the BEAGLE program. The VCF file is required to contain FORMAT fields with "GL" or "PL" tags, which can generally be output by SNP callers such as the GATK. Use of this option requires a chromosome to be specified via the "--chr" option. The resulting output file has the suffix ".BEAGLE.GL" or ".BEAGLE.PL" and contains genotype likelihoods for biallelic sites. This file is suitable for input into BEAGLE via the "like=" argument.

ADD COMMENT
0
Entering edit mode

That would be ideal but I’m running into the problem of having so many contigs (20k +) that I don’t know the best way to specify their names in the --chr flag, which doesn’t accept a list of chromosome names like one per line. Having all 20k names written on the command line or in a script fails because the argument is too long.

ADD REPLY

Login before adding your answer.

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