This is a test version of Biostars. For the public version, visit https://www.biostars.org.
How do I extract taxonomy/organism from NCBI .gb files?

Hello there,

I am trying to extract the taxonomy section from the NCBI .gbk file. How do I go about doing so?

Thanks!

ncbi

For individual files that information is in the flat file. Are you trying to do this in a large scale? If so, what have you tried so far? Read up on Entrez Direct here: https://www.ncbi.nlm.nih.gov/books/NBK179288/ and you should be able to get started. Good luck!

1 answer

You can use this script that would parse any GenBank file with extension .gbff or .gbk in a specific location or present working directory and prints the sequence accession number and taxonomy ID.

Thank you! Will try it!

Log in to answer this question.