How to intersect data from four different annotated files using ubuntu commands?
1
0
Entering edit mode
5.4 years ago
otokha • 0

I have three affected and one unaffected VCF and annotated files from exome analysis. I want to compare the variants present in the affecteds and absent in unaffected data.

How can I pull out the variants unique to affected individuals from all the four files?

Kindly help.

ubuntu vcf annotation filtering variants • 1.1k views
ADD COMMENT
2
Entering edit mode
5.4 years ago

merge the vcf files with bcftools and the use an expression to test the 3 affected genotypes and the non-affected genotype:

bcftools merge src/test/resources/S[1-4].vcf.gz | \
bcftools  view -i '(GT[0]=="AA" || GT[0]=="RA")  && (GT[1]=="AA" || GT[1]=="RA") && (GT[2]=="AA" || GT[2]=="RA") &&  (GT[3]=="RR" )'
ADD COMMENT
0
Entering edit mode

Thanks for the help. GT[1] == "AA" represents the missing variants among the affecteds data, is it?

ADD REPLY
1
Entering edit mode

AA = "alt+alt" homozygous for the alternative allele(s)

ADD REPLY
0
Entering edit mode

Thanks for timely help.

ADD REPLY
0
Entering edit mode

If an answer was helpful you should upvote it, if the answer resolved your question you should mark it as accepted.
Upvote|Bookmark|Accept

ADD REPLY

Login before adding your answer.

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