You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To allow an experiment to run custom behavior based on experiment
results, eg:
class MyWidget
include Scientist
def users
science "my-experiment" do |e|
e.use { control_method }
e.try { candidate_method }
# Slower candidates need further investigation
e.after_run do |result|
control_duration = result.control.duration
candidate_duration = result.candidates.first.duration
if candidate_duration - control_duration > 15
Logger.debug("Slow experiment candidate #{context}")
end
end
end
end
end
0 commit comments