package dataset
import "github.com/DataDog/sketches-go/dataset"
Index ¶
- type Constant
- type Dataset
- func NewDataset() *Dataset
- func (d *Dataset) Add(v float64)
- func (d *Dataset) LowerQuantile(q float64) float64
- func (d *Dataset) Max() float64
- func (d *Dataset) Merge(o *Dataset)
- func (d *Dataset) Min() float64
- func (d *Dataset) Quantile(q float64) float64
- func (d *Dataset) Sum() float64
- func (d *Dataset) UpperQuantile(q float64) float64
- type Exponential
- type Generator
- type Linear
- type LinearWithZeroes
- type Lognormal
- type Normal
- type Pareto
Types ¶
type Constant ¶
type Constant struct {
// contains filtered or unexported fields
}
Constant stream
func NewConstant ¶
func (*Constant) Generate ¶
type Dataset ¶
func NewDataset ¶
func NewDataset() *Dataset
func (*Dataset) Add ¶
func (*Dataset) LowerQuantile ¶
func (*Dataset) Max ¶
func (*Dataset) Merge ¶
func (*Dataset) Min ¶
func (*Dataset) Quantile ¶
Quantile returns the lower quantile of the dataset
func (*Dataset) Sum ¶
func (*Dataset) UpperQuantile ¶
type Exponential ¶
type Exponential struct {
// contains filtered or unexported fields
}
Exponential distribution
func NewExponential ¶
func NewExponential(rate float64) *Exponential
func (*Exponential) Generate ¶
func (g *Exponential) Generate() float64
type Generator ¶
type Generator interface { Generate() float64 }
type Linear ¶
type Linear struct {
// contains filtered or unexported fields
}
Linearly increasing stream
func NewLinear ¶
func NewLinear() *Linear
func (*Linear) Generate ¶
type LinearWithZeroes ¶
type LinearWithZeroes struct {
// contains filtered or unexported fields
}
Linearly increasing stream, with zeroes once every 2 values.
func NewLinearWithZeroes ¶
func NewLinearWithZeroes() *LinearWithZeroes
func (*LinearWithZeroes) Generate ¶
func (g *LinearWithZeroes) Generate() float64
type Lognormal ¶
type Lognormal struct {
// contains filtered or unexported fields
}
Lognormal distribution
func NewLognormal ¶
func (*Lognormal) Generate ¶
type Normal ¶
type Normal struct {
// contains filtered or unexported fields
}
Normal distribution
func NewNormal ¶
func (*Normal) Generate ¶
type Pareto ¶
type Pareto struct {
// contains filtered or unexported fields
}
Pareto distribution
func NewPareto ¶
func (*Pareto) Generate ¶
Source Files ¶
- Version
- v1.4.7 (latest)
- Published
- Feb 19, 2025
- Platform
- linux/amd64
- Imports
- 4 packages
- Last checked
- 1 week ago –
Tools for package owners.