Asciichartpy is a lightweight Python library for drawing nice-looking console ASCII line charts directly in your terminal. It offers simple, dependency-free charting for command-line applications and scripts. The current version is 1.5.25, with releases occurring periodically to address minor issues and improvements.
pip install asciichartpyVerified import paths — ran on the pinned version, not inferred.
This quickstart demonstrates how to plot a single numeric series and multiple series using `asciichartpy.plot`. It generates a sine wave as sample data and prints the ASCII chart directly to the console. The `height` option is used to control the chart's vertical size.
Ensure all elements in your input series are integers or floats before passing them to `plot()`.
If you have `series1` and `series2`, pass them as `asciichartpy.plot([series1, series2], ...)` not `asciichartpy.plot(series1, series2, ...)`. Each inner list represents one series.
Use a monospaced font, ensure your terminal window is sufficiently wide, and experiment with the `height` and `offset` options to optimize rendering for your environment.
Cleanse your data to ensure all values in the series are convertible to numbers. Example: `data = [float(x) for x in raw_data if x.isdigit()]`.
Call the correct function: `asciichartpy.plot(...)` or `from asciichartpy import plot; plot(...)`.
Ensure your terminal is using a UTF-8 encoding (e.g., `chcp 65001` on Windows CMD/PowerShell, or check locale settings on Linux/macOS). Using a modern terminal emulator (like Windows Terminal, Alacritty, iTerm2) and a suitable monospaced font (e.g., Fira Code, Source Code Pro) can resolve most rendering issues.
No dependency data recorded yet.