datasketches-cpp
Static Public Member Functions | List of all members
bounds_on_ratios_in_sampled_sets Class Reference

Bounds on ratios in sampled sets. More...

#include <bounds_on_ratios_in_sampled_sets.hpp>

Static Public Member Functions

static double lower_bound_for_b_over_a (uint64_t a, uint64_t b, double f)
 Return the approximate lower bound based on a 95% confidence interval. More...
 
static double upper_bound_for_b_over_a (uint64_t a, uint64_t b, double f)
 Return the approximate upper bound based on a 95% confidence interval. More...
 
static double get_estimate_of_b_over_a (uint64_t a, uint64_t b)
 Return the estimate of b over a. More...
 
static double estimate_of_a (uint64_t a, double f)
 Return the estimate of A. More...
 
static double estimate_of_b (uint64_t b, double f)
 Return the estimate of B. More...
 

Detailed Description

Bounds on ratios in sampled sets.

This class is used to compute the bounds on the estimate of the ratio |B| / |A|, where:

Member Function Documentation

◆ lower_bound_for_b_over_a()

static double lower_bound_for_b_over_a ( uint64_t  a,
uint64_t  b,
double  f 
)
inlinestatic

Return the approximate lower bound based on a 95% confidence interval.

Parameters
aSee class javadoc
bSee class javadoc
fthe inclusion probability used to produce the set with size a and should generally be less than 0.5. Above this value, the results not be reliable. When f = 1.0 this returns the estimate.
Returns
the approximate upper bound

◆ upper_bound_for_b_over_a()

static double upper_bound_for_b_over_a ( uint64_t  a,
uint64_t  b,
double  f 
)
inlinestatic

Return the approximate upper bound based on a 95% confidence interval.

Parameters
aSee class javadoc
bSee class javadoc
fthe inclusion probability used to produce the set with size a.
Returns
the approximate lower bound

◆ get_estimate_of_b_over_a()

static double get_estimate_of_b_over_a ( uint64_t  a,
uint64_t  b 
)
inlinestatic

Return the estimate of b over a.

Parameters
aSee class javadoc
bSee class javadoc
Returns
the estimate of b over a

◆ estimate_of_a()

static double estimate_of_a ( uint64_t  a,
double  f 
)
inlinestatic

Return the estimate of A.

See class javadoc.

Parameters
aSee class javadoc
fthe inclusion probability used to produce the set with size a.
Returns
the approximate lower bound

◆ estimate_of_b()

static double estimate_of_b ( uint64_t  b,
double  f 
)
inlinestatic

Return the estimate of B.

See class javadoc.

Parameters
bSee class javadoc
fthe inclusion probability used to produce the set with size b.
Returns
the approximate lower bound

The documentation for this class was generated from the following file: