通过使用Entrez、Efetch从分类数据库中搜索沿袭返回空结果

2024-06-17 14:24:32 发布

您现在位置:Python中文网/ 问答频道 /正文

我使用biopython从分类数据库中搜索血统信息,但它返回空!你知道吗

我昨天(2016/3/15)就可以用了!但现在我不能用了(2016/03/16)!你知道吗

我用的代码在这里

>>> from Bio import Entrez   
>>> Entrez.email = "myemail@gmail.com"   
>>> handle = Entrez.esearch(db="Taxonomy", term="Cypripedioideae")    
>>> record = Entrez.read(handle)   
>>> record["IdList"]   
['158330']  
>>> record["IdList"][0]  
'158330'  
>>> handle = Entrez.efetch(db="Taxonomy", id="158330", retmode="xml")  
>>> records = Entrez.read(handle)   
>>> records[0].keys()  
Traceback (most recent call last):  
File "<stdin>", line 1, in <module>  
IndexError: list index out of range
>>> records
[]  #I can't understand why it returns empty today? 

Tags: 代码from信息数据库readdb分类entrez