Extract specific variant genome ID from a VCF file
1
0
Entering edit mode
4.2 years ago
Chvatil ▴ 130

Hello I have a specific variant file (vcf) dowload from

ftp:/­/­ftp.­1000genomes.­ebi.­ac.­uk/­vol1/­ftp/­data_collections/­1000_genomes_project/­release/­20190312_biallelic_SNV_and_INDEL/­ALL.­chr9.­shapeit2_integrated_snvindels_v2a_27022019.­GRCh38.­phased.­vcf.­gz.­tbi

so I get a file called : ALL.­chr9.­shapeit2_integrated_snvindels_v2a_27022019.­GRCh38.­phased.­vcf wich is very huge and contains all the variant from the GRCh38 ref genome compared to all Human genomes.

but I'm only interested in the variant of the genome HG00479

Does someone have an idea how to extract this specific ones instead of all ?

Thank you very much

variant genome vcf • 872 views
ADD COMMENT
3
Entering edit mode
4.2 years ago

From bcftools' documentation:

bcftools view -s HG00479 -o HG00479.chr9.vcf ftp:/­/­ftp.­1000genomes.­ebi.­ac.­uk/­vol1/­ftp/­data_collections/­1000_genomes_project/­release/­20190312_biallelic_SNV_and_INDEL/­ALL.­chr9.­shapeit2_integrated_snvindels_v2a_27022019.­GRCh38.­phased.­vcf.­gz

Note that the file you mention in your question is the index of all the chr9 variants.

ADD COMMENT

Login before adding your answer.

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