View Source GrowthBook.ExperimentResult (GrowthBook v0.3.0)
Struct holding the results of an GrowthBook.Experiment
.
Holds the result of running an GrowthBook.Experiment
against a GrowthBook.Context
.
Link to this section Summary
Link to this section Types
Specs
t() :: %GrowthBook.ExperimentResult{ bucket: float(), feature_id: String.t(), hash_attribute: String.t(), hash_used?: boolean(), hash_value: String.t() | integer(), in_experiment?: boolean(), key: String.t(), name: String.t(), passthrough?: boolean(), sticky_bucket_used?: boolean(), value: term(), variation_id: integer() }
Experiment result
The result of running an GrowthBook.Experiment
given a specific GrowthBook.Context
in_experiment?
(boolean/0
) - Whether or not the user is part of the experimentvariation_id
(integer/0
) - The array index of the assigned variationvalue
(any/0
) - The array value of the assigned variationhash_used?
(boolean/0
) - If a hash was used to assign a variationhash_attribute
(String.t/0
) - The user attribute used to assign a variationhash_value
(String.t/0
) - The value of that attributefeature_id
(String.t/0
) - The id of the feature (if any) that the experiment came fromkey
(String.t/0
) - The unique key for the assigned variationbucket
(float/0
) - The hash value used to assign a variation (float from 0 to 1)name
(String.t/0
) - The human-readable name of the assigned variationpassthrough?
(boolean/0
) - Used for holdout groupssticky_bucket_used?
(boolean/0
) - If sticky bucketing was used to assign a variation
The variation_id
and value
should always be set, even when in_experiment?
is false.
The hash_attribute
and hash_value
should always be set, even when hash_used?
is false.
The key
should always be set, even if experiment.meta
is not defined or incomplete.
In that case, convert the variation's array index to a string (e.g. 0 -> "0") and use that as the key instead.