Fetch citation counts from CrossRef, OpenCitations, and Google Scholar.
Project description
citations_count_lib
Overview
citations_count is a Python library designed to fetch citation counts for academic publications from multiple sources, including CrossRef, OpenCitations, and Google Scholar.
This library provides a unified interface to retrieve citation counts using DOIs (Digital Object Identifiers).
Features
- Fetch citation counts from CrossRef, OpenCitations, and Google Scholar.
- Support for verbose logging to aid in debugging.
- Handles rate limiting by introducing delays between API calls.
Installation
To install the library, clone the repository and install the dependencies:
git clone https://github.com/ezefranca/citations_count_lib.git
cd citations_count_lib
pip install -r requirements.txt
Usage
from citations_count.core import fetch_multiple_citations
dois = [
"10.1109/SeGAH.2017.7939283",
"10.1109/SeGAH.2011.6165447",
"10.3390/info16030246",
"10.1038/s41586-020-2649-2"
]
results = fetch_multiple_citations(dois, delay=1.0, verbose=True)
for result in results:
print(result)
Example output:
[
{
"doi": "10.1109/SeGAH.2017.7939283",
"citations_crossref": 62,
"citations_opencitations": 64,
"citations_google_scholar": 160
},
{
"doi": "10.1109/SeGAH.2011.6165447",
"citations_crossref": 48,
"citations_opencitations": 48,
"citations_google_scholar": 116
},
{
"doi": "10.3390/info16030246",
"citations_crossref": 0,
"citations_opencitations": 0,
"citations_google_scholar": 0
},
{
"doi": "10.1038/s41586-020-2649-2",
"citations_crossref": 14710,
"citations_opencitations": None,
"citations_google_scholar": 22393
}
]
Logging
Verbose logging can be enabled by setting the verbose parameter to True. This will print detailed logs for debugging purposes.
Contributing
Contributions are welcome! Please open an issue or submit a pull request for any improvements or bug fixes.
License
This project is licensed under the MIT License. See the LICENSE file for details.
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 citations_count-0.1.0.tar.gz.
File metadata
- Download URL: citations_count-0.1.0.tar.gz
- Upload date:
- Size: 6.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4c2817657228fe95ef37e9b2df3bd115e6d815f3d5fe1e83fc5779937553cfa3
|
|
| MD5 |
96f2644b43364d5add96b48dec844c00
|
|
| BLAKE2b-256 |
5900358dce46676a7b550c9181e81699c9f10b901347d1fcbac9d06d793675ec
|
File details
Details for the file citations_count-0.1.0-py3-none-any.whl.
File metadata
- Download URL: citations_count-0.1.0-py3-none-any.whl
- Upload date:
- Size: 8.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7220f3e70421a4a50d34176ef5cf9db953abb6cf003e66d885634fa5af9d5ed2
|
|
| MD5 |
8ac5b474572ac4558678a0248798a10d
|
|
| BLAKE2b-256 |
9ca3bd6a16be36effd14d5b5d4be49c601d53ab006d1e82432de6659930832d5
|