Question: bcftools split and filter variants in vcf
2
gravatar for bioguy24
19 months ago by
bioguy24190
Chicago
bioguy24190 wrote:

I use bcftools norm to split and left-normalize variants (like the line in file). After norm the variant is split correctly and annotated, my question is can the AF tag be used to filter out AF= below 20% in the command or is there another? So in this case the first split vatiant is filtered out. Thank you :).

before bcftools norm
chr4    187004216   .   TC  T,TT

after bcftools norm
chr4    187004217   187004217   C   -
AF=0.0305344;AO=130
chr4    187004217   187004217   C   T
AF=0.969466;AO=673

desired output
chr4    187004217   187004217   C   T
AF=0.969466;AO=673
bcftools ngs • 1.0k views
ADD COMMENTlink modified 19 months ago by Kevin Blighe47k • written 19 months ago by bioguy24190
2
gravatar for Kevin Blighe
19 months ago by
Kevin Blighe47k
Kevin Blighe47k wrote:

You are certainly correct to normalise the file prior to filtering; otherwise, you would obtain unexpected results.

To filter on AF, use bcftools view, specifically the following parameters:

-q/Q, --min-af/--max-af

Kevin

ADD COMMENTlink written 19 months ago by Kevin Blighe47k
1

Thank you very much :).

ADD REPLYlink written 18 months ago by bioguy24190
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: 660 users visited in the last hour