Documentation
¶
Overview ¶
Package abtest provides protocol A/B testing framework.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Experiment ¶
type Experiment struct {
Name string `json:"name"`
Protocol string `json:"protocol"`
Variants []Variant `json:"variants"`
}
Experiment represents an A/B test experiment.
func NewExperiment ¶
func NewExperiment(name, protocol string) *Experiment
NewExperiment creates a new A/B test experiment.
func (*Experiment) AddVariant ¶
func (e *Experiment) AddVariant(name, version string, weight float64)
AddVariant adds a variant.
func (*Experiment) Analyze ¶
func (e *Experiment) Analyze() string
Analyze analyzes experiment results and returns a recommendation.
Click to show internal directories.
Click to hide internal directories.