Function prometheus::linear_buckets [] [src]

pub fn linear_buckets(start: f64, width: f64, count: usize) -> Result<Vec<f64>>

linear_buckets creates count buckets, each width wide, where the lowest bucket has an upper bound of start. The final +Inf bucket is not counted and not included in the returned slice. The returned slice is meant to be used for the Buckets field of HistogramOpts.

The function returns an error if count is zero or width is zero or negative.