Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func New ¶
func New(sketch *CountMinSketch, k int) *summary
Types ¶
type CountMinSketch ¶
type CountMinSketch struct {
// contains filtered or unexported fields
}
func NewCountMinSketch ¶
func NewCountMinSketch(numHashes, numBuckets uint32) *CountMinSketch
func WithEstimates ¶
func WithEstimates(epsilon, delta float64) (sk *CountMinSketch)
WithEstimates creates a Count-Min Sketch with given error rate and confidence. Accuracy guarantees will be made in terms of a pair of user specified parameters, ε and δ, meaning that the error in answering a query is within a factor of ε with probability δ
func (*CountMinSketch) Estimate ¶
func (cms *CountMinSketch) Estimate(item string) int
func (*CountMinSketch) Increment ¶
func (cms *CountMinSketch) Increment(item string) int
Click to show internal directories.
Click to hide internal directories.