Entering edit mode
4 weeks ago
Kyra
•
0
Hi,
I have a VCF from a WGS sequencing run that has phasing information (0/1, 1/1, 1/0). How can I use something like bcftools to query it so I separate out variants on each chromatid?
I want two VCFs that I can load into a genome browser to visualise it (so that I can see if the variants on a particular chromosome line up with CNVs/SNVs on the other.) Im thinking I could search each line and copy them to a new file with a bash script but is there a better way?
Thanks. Kyra
variants that use a slash (/) are actually unphased. if they have a vertical bar (|) then they are phased. disclaimer: I made this, but we made a visualizer for variants in jbrowse that can show each part of phased variants on different lines visually. this is an example tutorial showing a trio can be visualized, but it would also work with just a single sample VCF https://jbrowse.org/jb2/docs/user_guides/analyze_trio/
haha yes I was actually splitting the VCF to load them into jbrowse2. My organisation creates individual VCFs per sample even in trios but would concatenating all 3 VCFs together work for this trio visualisation? Also apologies, I did mean to type "|" just put slash out of habit but thank you!
Also just to note, currently attempting to test jbrowse2 for integration within my hospital, would love to have a talk about getting the most out of it
That would be great, would be happy to chat https://jbrowse.org/jb2/contact/ For that visualization it would indeed want a single multi-sample VCF file. Potentially you can merge VCFs together with something like "bcftools merge" https://samtools.github.io/bcftools/bcftools.html#merge but there might be other options too