Question: finding unique mutations from a multi-sample VCF
0
gravatar for firatuyulur
2.4 years ago by
firatuyulur280
firatuyulur280 wrote:

Hi all,

I have gone through many posts and couldnt find my answer. I have a vcf file of 4 samples. What I want to reach from it is the list of unique mutations among samples. Example, at position N their genotypes are as ; 0/1 0/0 0/0 0/0. In such case, this is a unique mutation for sample1 at position N. I have gathered an R script where it does what I want at the end but it is not a very useful way of doing such trivial thing. Any recommendation would be helpful.

snp vcf • 949 views
ADD COMMENTlink modified 2.4 years ago by Pierre Lindenbaum122k • written 2.4 years ago by firatuyulur280
2
gravatar for Floris Brenk
2.4 years ago by
Floris Brenk890
USA
Floris Brenk890 wrote:

Why not filter on minor allele frequency using vcftools?

Using for example --max-maf you can set the maximum in this case you have 8 alleles so max allele frequency would be 0.125

http://vcftools.sourceforge.net/man_latest.html

ADD COMMENTlink written 2.4 years ago by Floris Brenk890
0
gravatar for Pierre Lindenbaum
2.4 years ago by
France/Nantes/Institut du Thorax - INSERM UMR1087
Pierre Lindenbaum122k wrote:

using vcfilterjs

 java -jar  dist/vcffilterjs.jar  -e 'function accept(v) { var i,n=0;for(i=0;i< v.getNSamples();++i) { var g=v.getGenotype(i); n+=(g.isHomVar() || g.isHet() ?1:0);} return n==1;} accept(variant);' input.vcf > output.vcf
ADD COMMENTlink written 2.4 years ago by Pierre Lindenbaum122k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1420 users visited in the last hour