Skip to main content

Tools for using article data in Python.

Project description

elife-tools

Latest Version https://coveralls.io/repos/elifesciences/elife-tools/badge.svg?branch=master&service=github

Tools for using article data in Python

Supports

  • Python >=3.5

Non-Python dependencies

  • libxml2 (Ubuntu, Arch)

Install for users

Install via pip:

$ pip install elifetools

You might need to install libxml manually first

$ sudo STATIC_DEPS=true pip install lxml==3.4.1

To install the latest version directly from git

$ pip install git+https://github.com/elifesciences/elife-tools.git@master

or you can add it to your project’s requirements.txt file

git+https://github.com/elifesciences/elife-tools.git@master

Install for developers

Clone the git repo

Make a virtualenv (optional)

Then

$ python setup.py install

Example usage

>>> from elifetools import parseJATS as parser
>>> soup = parser.parse_document('sample-xml/elife-kitchen-sink.xml')
>>> print(parser.doi(soup))

More code examples can be found in tests/basic_usage_test.py

Testing

You can run the full automated test suite from the base folder with:

$ python -m unittest discover elifetools/tests

or you can run tests with coverage:

$ coverage run -m unittest discover elifetools/tests

and then view the coverage report:

$ coverage report -m

License

The MIT License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for elifetools, version 0.3.1
Filename, size File type Python version Upload date Hashes
Filename, size elifetools-0.3.1-py3-none-any.whl (59.5 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size elifetools-0.3.1.tar.gz (57.3 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page