pub struct HeatmapPlot<'a> { /* private fields */ }Expand description
Builder for heatmap plots with extensive customization options
Implementations§
Source§impl<'a> HeatmapPlot<'a>
impl<'a> HeatmapPlot<'a>
Sourcepub fn new(label: &'a str, values: &'a [f64], rows: usize, cols: usize) -> Self
pub fn new(label: &'a str, values: &'a [f64], rows: usize, cols: usize) -> Self
Create a new heatmap plot with the given label and data
§Arguments
label- The label for the heatmapvalues- The data values in row-major order (unless ColMajor flag is set)rows- Number of rows in the datacols- Number of columns in the data
Sourcepub fn with_scale(self, min: f64, max: f64) -> Self
pub fn with_scale(self, min: f64, max: f64) -> Self
Set the color scale range (min, max) If both are 0.0, auto-scaling will be used
Sourcepub fn with_label_format(self, fmt: Option<&'a str>) -> Self
pub fn with_label_format(self, fmt: Option<&'a str>) -> Self
Set the label format for values (e.g., “%.2f”, “%.1e”) Set to None to disable labels
Sourcepub fn with_bounds(self, min_x: f64, min_y: f64, max_x: f64, max_y: f64) -> Self
pub fn with_bounds(self, min_x: f64, min_y: f64, max_x: f64, max_y: f64) -> Self
Set the drawing area bounds in plot coordinates
Sourcepub fn with_bounds_points(self, min: ImPlotPoint, max: ImPlotPoint) -> Self
pub fn with_bounds_points(self, min: ImPlotPoint, max: ImPlotPoint) -> Self
Set the drawing area bounds using ImPlotPoint
Sourcepub fn with_flags(self, flags: HeatmapFlags) -> Self
pub fn with_flags(self, flags: HeatmapFlags) -> Self
Set heatmap flags for customization
Sourcepub fn with_item_flags(self, flags: ItemFlags) -> Self
pub fn with_item_flags(self, flags: ItemFlags) -> Self
Set common item flags for this plot item (applies to all plot types)
Sourcepub fn column_major(self) -> Self
pub fn column_major(self) -> Self
Use column-major data ordering instead of row-major
Trait Implementations§
Source§impl<'a> Plot for HeatmapPlot<'a>
impl<'a> Plot for HeatmapPlot<'a>
Source§impl<'a> PlotItemStyled for HeatmapPlot<'a>
impl<'a> PlotItemStyled for HeatmapPlot<'a>
fn style_mut(&mut self) -> &mut PlotItemStyle
Source§fn with_style(self, style: PlotItemStyle) -> Self
fn with_style(self, style: PlotItemStyle) -> Self
Replace the entire item style override for this plot.
Source§fn with_line_color(self, color: [f32; 4]) -> Self
fn with_line_color(self, color: [f32; 4]) -> Self
Set the line color. Use the alpha channel to control line transparency.
Source§fn with_line_weight(self, weight: f32) -> Self
fn with_line_weight(self, weight: f32) -> Self
Set the line width in pixels.
Source§fn with_fill_color(self, color: [f32; 4]) -> Self
fn with_fill_color(self, color: [f32; 4]) -> Self
Set the fill color.
Source§fn with_fill_alpha(self, alpha: f32) -> Self
fn with_fill_alpha(self, alpha: f32) -> Self
Set the fill alpha multiplier used for fills and marker faces.
Source§fn with_marker(self, marker: Marker) -> Self
fn with_marker(self, marker: Marker) -> Self
Set the marker type.
Source§fn with_marker_size(self, size: f32) -> Self
fn with_marker_size(self, size: f32) -> Self
Set the marker size in pixels.
Source§fn with_marker_line_color(self, color: [f32; 4]) -> Self
fn with_marker_line_color(self, color: [f32; 4]) -> Self
Set the marker outline color.
Source§fn with_marker_fill_color(self, color: [f32; 4]) -> Self
fn with_marker_fill_color(self, color: [f32; 4]) -> Self
Set the marker fill color.
Auto Trait Implementations§
impl<'a> Freeze for HeatmapPlot<'a>
impl<'a> RefUnwindSafe for HeatmapPlot<'a>
impl<'a> Send for HeatmapPlot<'a>
impl<'a> Sync for HeatmapPlot<'a>
impl<'a> Unpin for HeatmapPlot<'a>
impl<'a> UnsafeUnpin for HeatmapPlot<'a>
impl<'a> UnwindSafe for HeatmapPlot<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more