Add a box plot diagram.
(&mut self, mut box_plot: crate::BoxPlot)
| 2129 | |
| 2130 | /// Add a box plot diagram. |
| 2131 | pub fn box_plot(&mut self, mut box_plot: crate::BoxPlot) { |
| 2132 | if box_plot.boxes.is_empty() { |
| 2133 | return; |
| 2134 | } |
| 2135 | |
| 2136 | // Give the elements an automatic color if no color has been assigned. |
| 2137 | if PlotItem::color(&box_plot) == Color32::TRANSPARENT { |
| 2138 | box_plot = box_plot.color(self.auto_color()); |
| 2139 | } |
| 2140 | self.items.push(Box::new(box_plot)); |
| 2141 | } |
| 2142 | |
| 2143 | /// Add a bar chart. |
| 2144 | pub fn bar_chart(&mut self, mut chart: crate::BarChart) { |
no test coverage detected