histwriter

package module
v0.0.0-...-2e44061 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 16, 2021 License: Apache-2.0 Imports: 4 Imported by: 14

README

hdrhistogram-writer GoDoc

API for writing HdrHistograms in a readable format consumable by http://hdrhistogram.github.io/HdrHistogram/plotFiles.html.

Documentation

Overview

Package histwriter contains functions for writing HdrHistograms in a readable format consumable by http://hdrhistogram.github.io/HdrHistogram/plotFiles.html.

Index

Constants

This section is empty.

Variables

View Source
var Logarithmic = Percentiles{
	0.0,
	10.0,
	20.0,
	30.0,
	40.0,
	50.0,
	55.0,
	60.0,
	65.0,
	70.0,
	75.0,
	77.5,
	80.0,
	82.5,
	85.0,
	87.5,
	88.75,
	90.0,
	91.25,
	92.5,
	93.75,
	94.375,
	95.0,
	95.625,
	96.25,
	96.875,
	97.1875,
	97.5,
	97.8125,
	98.125,
	98.4375,
	98.5938,
	98.75,
	98.9062,
	99.0625,
	99.2188,
	99.2969,
	99.375,
	99.4531,
	99.5313,
	99.6094,
	99.6484,
	99.6875,
	99.7266,
	99.7656,
	99.8047,
	99.8242,
	99.8437,
	99.8633,
	99.8828,
	99.9023,
	99.9121,
	99.9219,
	99.9316,
	99.9414,
	99.9512,
	99.9561,
	99.9609,
	99.9658,
	99.9707,
	99.9756,
	99.978,
	99.9805,
	99.9829,
	99.9854,
	99.9878,
	99.989,
	99.9902,
	99.9915,
	99.9927,
	99.9939,
	99.9945,
	99.9951,
	99.9957,
	99.9963,
	99.9969,
	99.9973,
	99.9976,
	99.9979,
	99.9982,
	99.9985,
	99.9986,
	99.9988,
	99.9989,
	99.9991,
	99.9992,
	99.9993,
	99.9994,
	99.9995,
	99.9996,
	99.9997,
	99.9998,
	99.9999,
	100.0,
}

Logarithmic percentile scale.

Functions

func WriteDistribution

func WriteDistribution(hist *hdrhistogram.Histogram, percentiles Percentiles, scaleFactor float64, writer io.Writer) error

WriteDistribution writes the percentile distribution of a Histogram in a format plottable by http://hdrhistogram.github.io/HdrHistogram/plotFiles.html to the given Writer. Percentiles is a list of percentiles to include, e.g. 10.0, 50.0, 99.0, 99.99, etc. If percentiles is nil, it defaults to a logarithmic percentile scale. The scaleFactor is used to scale values.

func WriteDistributionFile

func WriteDistributionFile(hist *hdrhistogram.Histogram, percentiles Percentiles, scaleFactor float64, file string) error

WriteDistributionFile writes the percentile distribution of a Histogram in a format plottable by http://hdrhistogram.github.io/HdrHistogram/plotFiles.html to the given file. If the file doesn't exist, it's created. Percentiles is a list of percentiles to include, e.g. 10.0, 50.0, 99.0, 99.99, etc. If percentiles is nil, it defaults to a logarithmic percentile scale. The scaleFactor is used to scale values.

Types

type Percentiles

type Percentiles []float64

Percentiles is a list of percentiles to include in a percentile distribution, e.g. 10.0, 50.0, 99.0, 99.99, etc.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL