This is a test version of Biostars. For the public version, visit https://www.biostars.org.
how to select longest isoform per gene in gtf

hi everyone

i downloaded a gff file for a vertebrate and converted it to gtf format using gffread. i want to use the gtf file to creat database for SnpEff. Now i am going to choose and maintain single isoform per gene (longest isoform) in gtf file.

anyone can advise me to do this?

thanks in advance

gene gtf annotation

2 answers

Using the cgat toolset it can be accomplished with:

cgat gtf2gtf --method=filter --filter-method=longest-transcript 

It is a very rich set of tools, so have a look at what else it does because it will make your like easier.

Hi, the following script is used to get longer gene/isoform (start and end) from GTF. You can modify this script to solve your task,

Log in to answer this question.