pub fn plot(&self, axis_positions: &[f64], stem_values: &[f64]) {
        let number_of_points = axis_positions.len().min(stem_values.len());
        // If there is no data to plot, we stop here
        if number_of_points == 0 {
            return;
        }
        unsafe {
            sys::ImPlot_PlotStemsdoublePtrdoublePtr(
                self.label.as_ptr() as *const c_char,
                axis_positions.as_ptr(),
                stem_values.as_ptr(),
                number_of_points as i32, // "as" casts saturate as of Rust 1.45. This is safe here.
                self.reference_y,
                0,                                 // No offset
                std::mem::size_of::<f64>() as i32, // Stride, set to one f64 for the standard use case
            );
        }
    }
/// Draw a previously-created stem plot. Use this in closures passed to
/// [`Plot::build()`](struct.Plot.html#method.build). The `axis_positions` specify where on the
/// X axis the stems are drawn, and the `stem_values` specify what values the stems have.
Draw a previously-created stem plot.
Draw a previously - created stem plot .
pub fn plot(&self, axis_positions: &[f64], stem_values: &[f64]) {
        let number_of_points = axis_positions.len().min(stem_values.len());
        // If there is no data to plot, we stop here
        if number_of_points == 0 {
            return;
        }
        unsafe {
            sys::ImPlot_PlotStemsdoublePtrdoublePtr(
                self.label.as_ptr() as *const c_char,
                axis_positions.as_ptr(),
                stem_values.as_ptr(),
                number_of_points as i32, // "as" casts saturate as of Rust 1.45. This is safe here.
                self.reference_y,
                0,                                 // No offset
                std::mem::size_of::<f64>() as i32, // Stride, set to one f64 for the standard use case
            );
        }
    }
pub fn plot ( & self , axis_positions : & [ f64 ] , stem_values : & [ f64 ] ) { let number_of_points = axis_positions . len ( ) . min ( stem_values . len ( ) ) ; // If there is no data to plot, we stop here if number_of_points == 0 { return ; } unsafe { sys :: ImPlot_PlotStemsdoublePtrdoublePtr ( self . label . as_ptr ( ) as * const c_char , axis_positions . as_ptr ( ) , stem_values . as_ptr ( ) , number_of_points as i32 , // "as" casts saturate as of Rust 1.45. This is safe here. self . reference_y , 0 , // No offset std :: mem :: size_of :: < f64 > ( ) as i32 , // Stride, set to one f64 for the standard use case ) ; } }
Draw a previously-created stem plot.
Draw a previously - created stem plot .
&self
axis_positions
&[f64]
stem_values
&[f64]
&self
axis_positions
&[f64]
stem_values
&[f64]