Blot is a plotting library written in C, that plots data onto a string buffer.
That's right, there are no images, just text -- see examples below.
Site: bartman.github.io/blot
GitHub: github.com/bartman/blot
Copyright © 2021 Bart Trojanowski
Licensed under LGPL v2.1, or any later version.
- plots to the console as text (by calling
printf()
) - very very fast (compared to python alternatives)
- very very memory usage friendly
- can plot multiple datasets on one canvas
- uses familiar figure based API (similar to existing python plotting frameworks)
- supports braille plotting (like plotille)
- 256 colour support
- data arrays can be provided in various types (
int16
,int32
,int64
,double
, orfloat
)
blot was only tested on Debian Linux. It is built using standard tools.
sudo apt install make ninja-build cmake libglib2.0-dev
blot is built using cmake and ninja. There is a top level Makefile only to
simplify the build process (it invokes cmake in the build
subdirectory).
make
blot is being used in other projects as a library, but it comes with some examples.
Generated from test-simple.c
./build/examples/test-simple
Generated from test-trig.c
./build/examples/test-trig
- different plotting modes like bar and histograms (currently only plots line/scatter)
- improve axis line and numbering (currently not very accurate)
- add axis labels and minor ticks (configurable)
- draw origin lines and minor tick lines (configurable)
Allow for swapping data from layer to allow for even faster plotting (allow blot to reuse existing allocated structures)
- create a figure
- all
blot_figure_scatter
multiple times, have it return theblot_layer
- call
blot_figure_render
andblot_screen_get_text
- then use
blot_layer_new_data
to swap the data - repeat from step (3)
- plotille - Python, "plot, scatter plots and histograms in the terminal using braille dots"
- Tables-and-Graphs - "C++ Console Table and Graph/Plot Libraries"