Question: Is there a way to create a gene neighborhood from a set of coordinates and a gff file
0
gravatar for apoire27
8 weeks ago by
apoire270
apoire270 wrote:

I have a set of coordinates for a theoretical gene and I want to make a gene neighborhood for it with a gff file for the organism is this possible without using bedtools?

my coordinate sets look as follows

sample:start:stop:strand
NZOQ01000006.1_108  : 113072:14901:1
ADD COMMENTlink modified 8 weeks ago by RamRS27k • written 8 weeks ago by apoire270

is this possible without using bedtools

Can I ask why you are specifying that exception? bedtools slop generally will do this.

ADD REPLYlink written 8 weeks ago by genomax84k

I was under the impression you need the input coordinates to be in bed format to use bedtools and mine are just the coordinates in a text file I have output from a hmm run. is this incorrect?

ADD REPLYlink written 8 weeks ago by apoire270

You could convert those easily to BED format.

$ more test
sample:start:stop:strand
NZOQ01000006.1_108:113072:14901:1
NZOQ01000006.1_108:113172:14961:1
NZOQ01000006.1_108:113272:14931:1
NZOQ01000006.1_108:113372:14991:1

$ awk -F ":" '{OFS="\t"}{if ($1 ~ /^NZ/) print $1,$2,$3}' test
NZOQ01000006.1_108  113072  14901
NZOQ01000006.1_108  113172  14961
NZOQ01000006.1_108  113272  14931
NZOQ01000006.1_108  113372  14991

Based on the comment you have below you are looking for bedtools intersect or bedops equivalent (@Alex may be by with that answer).

ADD REPLYlink written 8 weeks ago by genomax84k

What do you mean by a "gene neighbourhood"? Do you mean a fixed distance either side of the gene? Or do you want to use the midpoint between genes?

ADD REPLYlink written 8 weeks ago by i.sudbery7.8k

I am looking for the closest +/-10 genes from my coordinates

ADD REPLYlink written 8 weeks ago by apoire270
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: 1888 users visited in the last hour