Expand description
§rustplotlib
A visualization library for Rust inspired by D3.js.
§Features
This is a WIP, but so far the library supports the following chart types:
- Bar Chart (horizontal and vertical)
- Stacked Bar Chart (horizontal and vertical)
§Abstraction Layers
There are several abstractions at the foundation of this visualization library:
Page └- Grid └- Chart ├- Axes └- View └- Dataset
TODO represent the structure visually
Structs§
- Area
Series View - A View that represents data as a scatter plot.
- Axis
- An axis struct that represents an axis along a dimension of the chart.
- Chart
- The Chart struct definition. A Chart is the smallest entity that can be saved (the bigger one is a Page (TBD)).
- Color
- A struct that represents a color.
- Horizontal
BarView - A View that represents data as horizontal bars.
- Line
Series - Represents a point in a scatter plot.
- Line
Series View - A View that represents data as a scatter plot.
- Scale
Band - The scale to represent categorical data.
- Scale
Linear - The scale to represent categorical data.
- Scatter
View - A View that represents data as a scatter plot.
- Vertical
BarView - A View that represents data as vertical bars.
Enums§
- Axis
Position - Enum of possible axis positions on the chart.
- BarLabel
Position - Set the position of a bar’s label.
- Marker
Type - Define the possible types of points in a scatter plot.
- Point
Label Position - Define the possible locations of a point’s label.
Traits§
- BarDatum
- A trait that defines interaction with a data point used in a bar chart. This provides greater flexibility in using different data sources as one can simply implement this trait and be able to use that data in a bar chart.
- Point
Datum - A trait that defines interaction with a data point used in a scatter/line plots.
- Scale
- The Scale trait defines common operations on all scales.