bedtools intersect and find genes
1
0
Entering edit mode
3.4 years ago
hosin • 0

Hi there! I have tried the below command to find genes (in File2, a "gtf" file) which are overlapped with genomic regions in File1:

$ bedtools intersect -a File1.tab -b File2 -wa -wb > overlap-genes

File1: includes genomic regions such as: 1 79390 88028 File2: includes genomic regions and genes (reference).

Actually I want to find the genes which are exactly within genomic regions in the File1, No overlapping genes with regions (because maybe some part of genes are only overlap with regions no in the regions, that we do not want to select them). Is there someone to help me for improve the command. Thanks.

genome • 1.1k views
ADD COMMENT
0
Entering edit mode
3.4 years ago

These parameters are what you'll need to adjust to get what you want:

-f  Minimum overlap required as a fraction of A. Default is 1E-9 (i.e. 1bp).
-F  Minimum overlap required as a fraction of B. Default is 1E-9 (i.e., 1bp).
-r  Require that the fraction of overlap be reciprocal for A and B. In other words, 
if -f is 0.90 and -r is used, this requires that B overlap at least 90% of A and that 
A also overlaps at least 90% of B.
-e  Require that the minimum fraction be satisfied for A _OR_ B. In other words, 
if -e is used with -f 0.90 and -F 0.10 this requires that either 90% of A is covered 
OR 10% of B is covered. Without -e, both fractions would have to be satisfied.
ADD COMMENT

Login before adding your answer.

Traffic: 2307 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6