Question: How to Get only one annotation with the SnpEff annotation?
0
gravatar for mhmtgenc85
22 months ago by
mhmtgenc8540
Turkey
mhmtgenc8540 wrote:

Dear All,

As you know when annotationg a vcf file each line might have more than one annotation but I would like to get only one annotation for a line? the first one only if possible.

So thanks in advance.

snp snpeff variation annotation • 836 views
ADD COMMENTlink modified 22 months ago by Pierre Lindenbaum128k • written 22 months ago by mhmtgenc8540
1

a variant can overlap multiple transcripts with different consequences; So why would you want to do this ?

ADD REPLYlink modified 22 months ago • written 22 months ago by Pierre Lindenbaum128k

Yeah you are right but for some reason I only would like to get only the first annotation. :)

ADD REPLYlink written 22 months ago by mhmtgenc8540
0
gravatar for Pierre Lindenbaum
22 months ago by
France/Nantes/Institut du Thorax - INSERM UMR1087
Pierre Lindenbaum128k wrote:

using vcffilterjdk: http://lindenb.github.io/jvarkit/VcfFilterJdk.html

 java -jar dist/vcffilterjdk.jar -e 'final String ann="ANN";List<Object> atts = variant.getAttributeAsList(ann); return atts.size()<=1 ? variant : new VariantContextBuilder(variant).attribute(ann,atts.get(0)).make();' input1.vcf
ADD COMMENTlink written 22 months ago by Pierre Lindenbaum128k
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: 1549 users visited in the last hour