[Biopython] IMGT/HLA DB Access

Eyal Arian eyalarian at gmail.com
Tue Jan 28 18:42:44 UTC 2014


Hello,
I would like to access data directly from the imgt/hla database into BioPython: http://www.ebi.ac.uk/cgi-bin/ipd/imgt/hla/align.cgi

For example, the following doesn't work, but it may give you the idea of what I am trying to do:
>>> import Bio
>>> from Bio import Entrez
>>> Entrez.email = "eyalarian at gmail.com"
>>> handle = Entrez.esearch(db="x-imgt-hla", term="DPB1*01:01:01")
>>> record = Entrez.read(handle) 
Traceback (most recent call last): 
File "<stdin>", line 1, in <module> 
File "Bio/Entrez/__init__.py", line 372, in read 
record = handler.read(handle) 
File "Bio/Entrez/Parser.py", line 187, in read 
self.parser.ParseFile(handle) 
File "Bio/Entrez/Parser.py", line 325, in endElementHandler 
raise RuntimeError(value) 
RuntimeError: Invalid db name specified: x-imgt-hla 

Thanks!
E. Arian



More information about the Biopython mailing list