gmbecker / genbankr

http://bioconductor.org/packages/devel/bioc/html/genbankr.html
14 stars 9 forks source link

genbankr parsing of mitochondrial Genome D-loops #22

Closed sborstein closed 1 year ago

sborstein commented 1 year ago

Hi, Thanks for your work on genbankr, it is a really useful tool. I am looking at using genbankr as a dependency for a package I am developing. I'm currently trying to extract the mitochondrial D-loop from mitochondrial genomes using the otherFeatures function. However, it seems to be behaving oddly in that the D-loop annotation is being combined with the annotations for the tRNA preceeding it and it not returning the range for the D-loop, just the range for the tRNA. I've provided an example below in which you can see the issue in the last line of the otherFeatures output :

gb <- readGenBank(GBAccession("ON921056.1")) # get the Genbank annotation for accession 
otherFeatures(gb)[24]#line 24 for the tRNA is listed as tRNA tRNA-ProD-loop and has the position ranges for tRNA-Pro but not the D-loop

I have tried this with a number of mitochondrial genomes (MZ646791.1,MT437356.1, LC627429.1 in addition to others ) with D-loop annotations, all of thich behaved similarly. Is it possible to get this corrected so both the tRNA and the D-loop annotation and ranges are accessible through genbankr?

Thanks, -Sam Borstein

gmbecker commented 1 year ago

This should be fixed in version 1.27.1, which I just pushed both here and to the bioconductor git repo. So the devel version available through bioc should reflect the change after the next build cycle. Please give it a try and confirm it works for you.

sborstein commented 1 year ago

I installed from GitHub via devtools and it is seperating the D-loop from the tRNAs and providing the ranges. Thanks for pushing out the fix!