Python package to count and plot the number of downloads from Pypi.
Project description
pypiplot
- pypiplot is Python package to count and plot the number of downloads from Pypi.
Installation
- Install pypiplot from PyPI (recommended). pypiplot is compatible with Python 3.6+ and runs on Linux, MacOS X and Windows.
pip install pypiplot # normal install
pip install -U pypiplot # or update if needed
Import pypiplot package
import pypiplot as pypiplot
Example update repos to disk:
from pypiplot import pypiplot
# Download all data for github user.
pp = pypiplot(username='erdogant')
# Update all repos
pp.update()
# Update single repo
pp.update(repo=['bnlearn','hnet'])
Example show repo download stats:
from pypiplot import pypiplot
# Download all data for github user.
pp = pypiplot(username='erdogant')
# Get total stats across all repos
results = pp.stats()
# Get some stats
results = pp.stats(repo=['df2onehot','pca','bnlearn'])
print(results.keys())
# ['data', 'heatmap', 'n_libraries', 'repos']
# Print data
print(results['data'])
# bnlearn df2onehot pca
# date
# 2020-05-01 100.0 18.0 281.0
# 2020-05-02 6.0 4.0 260.0
# 2020-05-03 50.0 16.0 126.0
# 2020-05-04 82.0 64.0 86.0
# 2020-05-05 64.0 157.0 50.0
# ... ... ...
# 2020-09-11 148.0 213.0 78.0
# 2020-09-12 96.0 102.0 144.0
# 2020-09-13 12.0 42.0 197.0
# 2020-09-14 156.0 92.0 244.0
# 2020-09-15 40.0 76.0 225.0
Example make plots
pp.plot_year(title='pypiplot')
pp.plot(title='pypiplot')
Change some of the colors and the minimum cut-off value
pp.plot_year(vmin=100, cmap='interpolateYlOrRd')
pp.plot(vmin=100, cmap='interpolateYlOrRd')
Plot all repos for github username
# Download all data for github user.
pp = pypiplot(username='erdogant')
# Get total stats across all repos
results = pp.stats()
# Get some stats
results = pp.stats()
pp.plot_year(vmin=700, title='Total downloads across all repos')
pp.plot(vmin=100)
Run pypiplot from terminal
Arguments:
* "-u", "--username" : username github
* "-l", "--library" : library name(s)
* "-p", "--path" : path name to store plot.
* "-v", "--vmin" : minimun value of the figure.
> python pypiplot/pypiplot.py -u 'erdogant' -p 'C://pypi_heatmap.html' -v '700'
References
Maintainer
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pypiplot-2.0.0.tar.gz
(10.7 kB
view details)
Built Distribution
File details
Details for the file pypiplot-2.0.0.tar.gz
.
File metadata
- Download URL: pypiplot-2.0.0.tar.gz
- Upload date:
- Size: 10.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 425af7404b09b4e62c4157759a9d6db58ab035896f1f32f4f9c3040c17b4d39b |
|
MD5 | 29726fb2af5280fb8f3966e23e37b5b1 |
|
BLAKE2b-256 | 1d97750b731c28f3e2c790b2e1515d5c19af373a401d46c753b3245a6ccd5c3f |
File details
Details for the file pypiplot-2.0.0-py3-none-any.whl
.
File metadata
- Download URL: pypiplot-2.0.0-py3-none-any.whl
- Upload date:
- Size: 9.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0876b137437cc34f6c14178bba6309474c4b5ba33296aca2e8dcce351e8a3c89 |
|
MD5 | 22a5c2d61df5003552b4297490191827 |
|
BLAKE2b-256 | 732af3e6d4638923519fbd0460a95cb034489a28bd3bce302246441fb81ad168 |