pysparklines is a unicode sparkline generation library.
Project description
pysparkline
Python 3 clone of Zach Holman's BASH sparkline project
Takes series data via stdin, command line, or API and prints a sparkline representation.
Usage:
- $
sparkline 4 3 2 1
█▆▃▁
- $
echo "1.0 1.0 2.0 3.0 5.0 8.0 13.0" | sparkline
▁▁▂▂▃▅█
- $
seq 20 | sort -R | sparkline -r2
▃▁ █▂ ▂▆▅ ▄▇▆
██▃██▅▇▄▁███▃▇███▂█▆
- $
python3 -c "import sparkline; print(sparkline.sparkify([1.0, 2.0, 3.0, 4.0]))"
▁▃▆█
- $
python3 -c "import math, sparkline; print(sparkline.sparkify([math.cos(n/10.0) for n in range(-50, 50, 2)], rows=4))"
▁▃▅▇███▇▅▃▁
▅▂ ▃▆███████████▆▃ ▂
██▇▄▁ ▂▅█████████████████▅▂ ▁▄▇█
█████▆▄▃▁▁▁▂▃▅▇█████████████████████▇▅▃▂▁▁▁▃▄▆████
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
pysparklines-1.3.tar.gz
(4.9 kB
view hashes)
Built Distribution
Close
Hashes for pysparklines-1.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b28a953aca72ab5118c7876088e907777ab0582787aef9524f93521a4822f910 |
|
MD5 | aa6e0a3006665c843ca712e0826517b2 |
|
BLAKE2b-256 | 1dbc71c51611cca4bcfec9e5461168cc0e5c1dc8fa02d70c3f1630eed56c3711 |