Question: samtools view manual
0
gravatar for doramora
8 months ago by
doramora10
doramora10 wrote:

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

sequence • 398 views
ADD COMMENTlink modified 8 months ago by Morris_Chair150 • written 8 months ago by doramora10

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 8 months ago by ATpoint25k
0
gravatar for Morris_Chair
8 months ago by
Morris_Chair150
Morris_Chair150 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 8 months ago • written 8 months ago by Morris_Chair150

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 8 months ago by doramora10
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 8 months ago by Morris_Chair150

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

ADD REPLYlink written 8 months ago by doramora10
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: 871 users visited in the last hour