#plot #histogram #bar-charts #barchart

eb_bars

Tiny plot library for creating barcharts and histograms

12 releases (4 breaking)

Uses new Rust 2024

new 0.5.2 Mar 31, 2025
0.5.1 Mar 12, 2025
0.4.3 Mar 11, 2025
0.3.1 Mar 5, 2025
0.1.1 Feb 16, 2025

#78 in Visualization

Download history 82/week @ 2025-02-05 142/week @ 2025-02-12 23/week @ 2025-02-19 221/week @ 2025-02-26 703/week @ 2025-03-05 381/week @ 2025-03-12 1/week @ 2025-03-19 55/week @ 2025-03-26

1,205 downloads per month

MIT/Apache

78KB
740 lines

EB Bars - It's a Super Simple Barchart Library 🦀

  • Simple and good looking barcharts for Rust

So Simple that

  • you can only create barcharts and or histograms.
  • there are no external dependencies.
  • the only supported output is svg.
  • all bars are drawn with the rect svg element instead of for example the path element.
  • even your mom can use the API.

But despite being simple you can customize your barchart by

  • adding text in any of the four sides if you want.
  • setting font size for text.
  • applying custom colors on bars, lines, ticks/markers and text.
  • showing or hiding grid lines (both horizontal and vertical).
  • having bars with negative values be drawn downwards.
  • setting a custom resolution.
  • resizing the chart and move it in all directions for best fit.

Showcase

Click on any of the images below to view the code.

Getting Started

For now, refer to crate docs for how to produce nice looking plots or simply take a look at all the tests.

No runtime deps