How to convert SAM/BAM file to GTF/GFF file?
2
0
Entering edit mode
19 months ago
BioinfoBee • 0

Hello, Curious to know if there's a way to convert SAM/BAM file generated using minimap2 to GTF/GFF file. The purpose is to use it as transcript alignment evidence for EVM. Kindly suggest!

Regards, B

GTF SAM BAM GFF minimap2 • 2.5k views
ADD COMMENT
2
Entering edit mode
19 months ago

You can convert to BED format with

bedtools bamtobed

then either use the resulting BED file or transform that to GFF. But with the caveat that it is none of the attributes would be filled in, so it would be quite the minimal and simplistic GFF

a better solution would be to use a tool like miniprot

https://github.com/lh3/miniprot

to generate actual GFF files based on proteins aligned to genome

ADD COMMENT
2
Entering edit mode
7 months ago
Dr.Animo ▴ 130

You can try AGAT toolkit to convert sam/bam to gff.

agat_convert_minimap2_bam2gff

Or there is an indirect solution:

https://github.com/lh3/minimap2/issues/455

ADD COMMENT

Login before adding your answer.

Traffic: 2061 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