1pub mod density;
2pub mod histogram;
3pub mod spectral;
4pub mod traits;
5
6pub use density::DensityPlot;
7pub use histogram::HistogramPlot;
8pub use spectral::SpectralSignaturePlot;
9pub use traits::Plot;
10
11#[derive(Debug, Clone, Copy, PartialEq, Eq, serde::Serialize, serde::Deserialize)]
15#[serde(rename_all = "snake_case")]
16pub enum PlotType {
17 ScatterSolid,
19 Density,
21 ScatterColoredContinuous,
23 ScatterOverlay,
25 Contour,
27 ContourOverlay,
29 #[serde(alias = "dot")]
31 Dot,
32 Zebra,
34 Histogram,
36}
37
38impl Default for PlotType {
39 fn default() -> Self {
40 PlotType::Density
41 }
42}
43
44impl PlotType {
45 pub fn canonical(self) -> Self {
47 match self {
48 PlotType::Dot => PlotType::ScatterSolid,
49 other => other,
50 }
51 }
52}