NCBI的新RefSeq版本与Bio.Entrez.Parser兼容吗? [英] The new RefSeq release from NCBI is compatible with Bio.Entrez.Parser?
问题描述
我是python的新手,尤其是Biopython.我正在尝试使用Entrez.efetch
从XML文件中获取一些信息,然后再读取它.上周,该脚本运行良好:
I'm new with python and especially with Biopython. I'm trying to take some information from an XML file with Entrez.efetch
and then read it. Last week this script worked well:
handle = Entrez.efetch(db="Protein", id="YP_008872780.1", retmode="xml")
records = Entrez.read(handle)
但是现在我遇到一个错误:
But now I'm getting an Error:
> Bio.Entrez.Parser.ValidationError: Failed to find tag 'GBSeq_xrefs' in
the DTD. To skip all tags that are not represented in the DTD, please
call Bio.Entrez.read or Bio.Entrez.parse with validate=False.
所以我运行这个:
records = Entrez.read(handle, validate=False)
但是我仍然遇到错误:
TypeError: 'str' object does not support item assignment
经过研究,我意识到NCBI制作了有关RefSeq
的新更改,该RefSeq
在(GenPept的)xml文件中创建新标签
After some research I realized that NCBI made new changes concerning the RefSeq
which creates new tags in the xml file (of GenPept)
我是否需要在DTD中进行某些更改以支持这些新标签?
Do I need to change something in the DTD to support these new tags?
推荐答案
我的DTD文件似乎已过期.
可以在此处或
It appears that my DTD file was out of date.
A new version can be found here or here.
这篇关于NCBI的新RefSeq版本与Bio.Entrez.Parser兼容吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!