Structured Python interface to NCBI E-Utilities.
Project description
eutils is a Python package dedicated to searching for, fetching, and parsing records from NCBI using their E-utilities interface.
STATUS: This code is alpha. There are no known bugs, but the code supports only a limited subset of E-Utilities replies
Features
optional sqlite-based caching of compressed replies
automatic throttling
simple Pythonic interface for searching and fetching
“façades” over XML from replies provide access to essential attributes
A Quick Example
In [1]: import eutils.client
In [2]: esr = ec.esearch(db='gene',term='tumor necrosis factor')
In [3]: gb = ec.efetch(db='gene',id=esr.ids[0])
In [4]: gb.locus, gb.maploc, gb.description, gb.type
Out[4]: ('TP53', '17p13.1', 'tumor protein p53', 'protein-coding')
In [5]: [ str(r) for r in gb.references ]
Out[5]:
['GeneCommentary(acv=NC_000017.10,type=genomic,heading=Reference GRCh37.p13 Primary Assembly,label=chromosome 17 reference GRCh37.p13 Primary Assembly)',
'GeneCommentary(acv=NG_017013.2,type=genomic,heading=Reference assembly,label=RefSeqGene)',
'GeneCommentary(acv=NC_018928.2,type=genomic,heading=Alternate CHM1_1.1,label=chromosome 17 alternate CHM1_1.1)',
'GeneCommentary(acv=AC_000149.1,type=genomic,heading=Alternate HuRef,label=chromosome 17 alternate HuRef)']
In [6]: gb.references[0].acv
Out[6]: 'NC_000017.10'
In [7]: gb.references[0].products[0].acv
Out[7]: 'NM_001126112.2'
In [8]: gb.references[0].products[0].genomic_coords.strand
Out[8]: -1
In [9]: gb.references[0].products[0].genomic_coords.intervals
Out[9]:
[(7590694, 7590868),
(7579838, 7579937),
(7579699, 7579721),
(7579311, 7579590),
(7578370, 7578554),
(7578176, 7578289),
(7577498, 7577608),
(7577018, 7577155),
(7576852, 7576926),
(7573926, 7574033),
(7571719, 7573008)]
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file eutils-0.0.2.tar.gz.
File metadata
- Download URL: eutils-0.0.2.tar.gz
- Upload date:
- Size: 214.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
87ca99e1639e57ebf7a457f1b4bc0d6502a964432db09c272c2b02d85a0de0fd
|
|
| MD5 |
0abced3f285a83c3bc556dd6b2561871
|
|
| BLAKE2b-256 |
c2a9d4bbacc944ead0a4cc0f680e8156451566c27166798c9201c8352b4e7c41
|
File details
Details for the file eutils-0.0.2-py2.7.egg.
File metadata
- Download URL: eutils-0.0.2-py2.7.egg
- Upload date:
- Size: 33.4 kB
- Tags: Egg
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0462ead9e4a8afb0f6d2d4f3a2a7055d2c9a45c5b78d3ffa8533e6ca19adc4f1
|
|
| MD5 |
a0bb842fe39ca424fc2dbf561cca12f8
|
|
| BLAKE2b-256 |
32fb299215caf4e0b0fc50a17b57a216c1eefa9876c36039c56410f96b7f8837
|