Skip to main content

PyMed - PubMed Access through Python

PyMed is a Python library that provides access to PubMed through the PubMed API.

Why this library?

The PubMed API is not very well documented and querying it in a performant way is too complicated and time consuming for researchers. This wrapper provides access to the API in a consistent, readable and performant way.

Features

This library takes care of the following for you:

  • Querying the PubMed database (with the standard PubMed query language)
  • Batching of requests for better performance
  • Parsing and cleaning of the retrieved articles

Examples

For full (working) examples have a look at the examples/ folder in this repository. In essence you only need to import the PubMed class, instantiate it, and use it to query:

from pymed import PubMed
pubmed = PubMed(tool="MyTool", email="my@email.address")
results = pubmed.query("Some query", max_results=500)

Notes on the API

The original documentation of the PubMed API can be found here: PubMed Central. PubMed Central kindly requests you to:

  • Do not make concurrent requests, even at off-peak times; and
  • Include two parameters that help to identify your service or application to our servers
    • tool should be the name of the application, as a string value with no internal spaces, and
    • email should be the e-mail address of the maintainer of the tool, and should be a valid e-mail address.

Notice of Non-Affiliation and Disclaimer

The author of this library is not affiliated, associated, authorized, endorsed by, or in any way officially connected with PubMed, or any of its subsidiaries or its affiliates. The official PubMed website can be found at https://www.ncbi.nlm.nih.gov/pubmed/.

Metadata

Release files for pymed 0.8.9

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pymed 0.8.9
File Size Uploaded
pymed-0.8.9.tar.gz 258.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pymed 0.8.9
File Interpreter ABI Platform
pymed-0.8.9-py3-none-any.whl Python 3 none any Details

Total release size: 267.8 kB

Release files / pymed-0.8.9.tar.gz

Download URL pymed-0.8.9.tar.gz
Size 258.2 kB
Tags Source
SHA-256 checksum
How to use checksums
3523b9655c39d2caef1c25582f29d0687ea269728d1b90b5e28e9c6b2dbff538
BLAKE2b-256 checksum
How to use checksums
24ba936db5a8a4d015f0c61106a11f01d85c73b580320b26b76be6af690899c6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.4.2 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.7.1

Release files / pymed-0.8.9-py3-none-any.whl

Download URL pymed-0.8.9-py3-none-any.whl
Size 9.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
bdd65ebd6448cc05d6d6134d53b38f8f0b77c0734fc40c33976656799168ae03
BLAKE2b-256 checksum
How to use checksums
56c30a260bd7b8e2d021097954accefb749f13e8fbd6b673293d33eac0905174
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.4.2 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.7.1

Release history Release notifications | RSS feed

This release

0.8.9 This release

2 release files

0.8.7

2 release files

0.8.4

2 release files

0.8.3

2 release files

0.8.2

2 release files

0.8.1

2 release files

0.8.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page