Integrate rich and sparklines libraries
Project description
Something like this:
import os
import random
import time
from rich.console import Console
from rich_sparklines import Graph
console = Console()
def main():
graph = Graph("connections", lambda: random.randint(0, 20))
while True:
graph.update()
os.system("cls")
console.print(graph)
time.sleep(1)
if __name__ == "__main__":
main()
will produce something like this:
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
rich_sparklines-0.1.5.tar.gz
(2.0 kB
view hashes)
Built Distribution
Close
Hashes for rich_sparklines-0.1.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2001de32c6dbe33a925a5cd53907c0b4e06e1eabe507d3cbf26f25ea7e02a126 |
|
MD5 | 037543546bcf8cb1b0b12acb81a57060 |
|
BLAKE2b-256 | 1eb6795e6767460b7ce3c7ff7493664d4637a5ecdb1ba09a9a8d7c55efadd98a |