Genome Analysis Toolkit

Variant Discovery in High-Throughput Sequencing Data

GATK process banner

Need Help?

Search our documentation

Community Forum

Hi, How can we help?

Developed in the Data Sciences Platform at the Broad Institute, the toolkit offers a wide variety of tools with a primary focus on variant discovery and genotyping. Its powerful processing engine and high-performance computing features make it capable of taking on projects of any size. Learn more

SelectVariants to get a vcf file with 1 individual from a vcf file with 3 individuals

0

3 comments

  • Avatar
    danilovkiri

    Hi Linda Do

    Such simple tasks do not require such complex solutions. There is a BCFtools package for any manipulations with VCF files. All you have to do is to run

    bcftools view -O v -o <output_vcf_file> -s <sample_name> <input_vcf_file> 

    The sample names in your VCF are 10017333.1_CS-64, 10017333.1_CS-65 and 10017333.1_CS-66. You have to know which one corresponds to a child.

     

    1
    Comment actions Permalink
  • Avatar
    Linda Do

    Thank you so much!

     

    I used:

    bcftools view -O v -o CS64.vcf -s 10017333.1_CS-64 craSyn-Trio2.recode.vcf

    And it worked!
    0
    Comment actions Permalink
  • Avatar
    ABours

    Hi Linda Do,

    The only problem with your code was that you forgot to put a "-" before sn, like this "-sn".

    Just in case anyone else stumbles on this :)

    Best,

    1
    Comment actions Permalink

Please sign in to leave a comment.

Powered by Zendesk