Question: samtools view manual
0
gravatar for doramora
7 days ago by
doramora0
doramora0 wrote:

Hi! Could you please explain me the differense between -f and -F in samtools view while filtering bam file?

sequence • 140 views
ADD COMMENTlink modified 7 days ago by Morris_Chair50 • written 7 days ago by doramora0

What is unclear based on the entry in the manual?

-f INT
Only output alignments with all bits set in INT present in the FLAG field. INT can be specified in hex by beginning with `0x' (i.e. /^0x[0-9A-F]+/) or in octal by beginning with `0' (i.e. /^0[0-7]+/) [0].

-F INT
Do not output alignments with any bits set in INT present in the FLAG field. INT can be specified in hex by beginning with `0x' (i.e. /^0x[0-9A-F]+/) or in octal by beginning with `0' (i.e. /^0[0-7]+/) [0].
ADD REPLYlink written 7 days ago by ATpoint14k
0
gravatar for Morris_Chair
7 days ago by
Morris_Chair50
ISBReMIT
Morris_Chair50 wrote:

Hi doramora, those are samtools options,

-f (required flag) -F (filtering flag)

Let say that you want to count all entries mapping to the positive strand, you can use this called "flag", -F 16 where you are filtering the reverse strand.

In this website as well as many others more, you can find a specific number based on what you require or filtering

https://www.samformat.info/sam-format-flag

all the best :)

ADD COMMENTlink modified 7 days ago • written 7 days ago by Morris_Chair50

thank you for the website! i have found, that i've got 4 Flag, but i still can't understand, where do i need to use -f

ADD REPLYlink written 7 days ago by doramora0
1

it depends on what you want to use or not, for example "do this" -f or "don't do this" -F , followed by the number which describes the action

I hope that is clear

ADD REPLYlink written 7 days ago by Morris_Chair50

It is clear! Thank you a lot! My mind feels better)

ADD REPLYlink written 7 days ago by doramora0
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: 2212 users visited in the last hour