lichtung-plot 0.1.0

Strongly typed scientific plotting with deterministic SVG and PNG output
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
//! Plot construction, layout, rendering, and output errors.

/// Error returned by plotting operations.
#[derive(Debug, thiserror::Error)]
pub enum Error {
    /// Filesystem input or output failed.
    #[error("I/O error: {0}")]
    Io(#[from] std::io::Error),
    /// Input data or a data-bound visual option is invalid.
    #[error("data error: {0}")]
    Data(String),
    /// Layout, backend, font, or output rendering failed.
    #[error("render error: {0}")]
    Render(String),
}

/// Result returned by plotting operations.
pub type Result<T> = std::result::Result<T, Error>;