Question: How To Merge Gff Files
gravatar for upendrakumar.devisetty
5.9 years ago by
United States
upendrakumar.devisetty350 wrote:

Hi, I was wondering if anyone know how to merge 2 or more gff files to make a consensus gff file? I have gtf file from tophat/cufflinks pipeline gff file from velvet assembly and i would like to merge these two to the already annotated gff file. The idea is to have one gff file instead of three gff files so that i can load this as track on my Genome Browser. Thanks in advance

gff merge • 5.8k views
ADD COMMENTlink modified 5.9 years ago by Alex Reynolds27k • written 5.9 years ago by upendrakumar.devisetty350

Any reason to not simply load three separate files? Alternatively, you can simply concatenate them and sort by chromosome location.

ADD REPLYlink written 5.9 years ago by Sean Davis25k

No particular reason..I want to all three files separately along with a fourth file indicating the consensus annotation which users might feel more convenient dealing with.

ADD REPLYlink written 5.9 years ago by upendrakumar.devisetty350
gravatar for Alex Reynolds
5.9 years ago by
Alex Reynolds27k
Seattle, WA USA
Alex Reynolds27k wrote:

One way to do this is to start by converting them to sorted UCSC BED with BEDOPS gtf2bed and sort-bed. Here's a quick way to convert a bunch of files if you use a bash shell:

$ for i in `ls *.gtf`; \ 
    do gtf2bed < $i > $i.converted.bed; \ 

Then do a multiset union set operation with BEDOPS bedops to make a single BED file called answer.bed that can be loaded into your genome browser instance:

$ bedops --everything *.converted.bed | cut -f1-6 - > answer.bed
ADD COMMENTlink modified 4.8 years ago • written 5.9 years ago by Alex Reynolds27k

Hi Alex,

I have done genome guided assembly using StringTie and it also generated a gff file. I also have already reported CDS gff. I want to merge both gff and want to extract consensus sequences from genome.

ADD REPLYlink written 23 months ago by Bioinfonext140
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 807 users visited in the last hour