Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ability to change variants? #19

Closed
jasonm opened this issue Sep 28, 2011 · 2 comments
Closed

Ability to change variants? #19

jasonm opened this issue Sep 28, 2011 · 2 comments

Comments

@jasonm
Copy link

jasonm commented Sep 28, 2011

Hello,

I have the following scenario:

  • Previously I was testing experiment "landing_page" with variants "original" and "new_copy".
  • We decided to run a new test.
  • We replaced this test with a new one, same experiment name "landing_page" with variants "original" and "screencast_and_testimonials".
  • Split will now only serve variant "original"
  • If you visit http://domain.com/?landing_page=screencast_and_testimonials, the screencast_and_testimonials variant is displayed to the user. However, we use the following code to record the AB variant into KISSmetrics, and when we manually request screencast_and_testimonials, it was being recorded as new_copy (variant Resetting an experiment doesn't reset existing participants #2 from the prior experiment):
  <% Split::Experiment.all.each do |experiment| %>
    <% km.set(experiment.name, ab_test(experiment.name, *experiment.alternative_names)) %>
  <% end %>

Is this expected behavior? e.g should we not reuse an experiment name with new sets of variants?

(As an aside, is there a better way to record the variants into KM other than that snippet?)

Thanks,
-Jason

@ghost ghost assigned andrew Sep 28, 2011
@andrew
Copy link
Member

andrew commented Sep 30, 2011

Experiments have the concept of versions, if you change alternatives or reset an experiment it should bump the version of the experiment, this is because the user only has the experiment name and a single alternative stored in their cookie.

With no way to expire their cookie, incrementing the version (which stores the experiment as experiment:version in the cookie) means that the user should receive a new alternative from the second version of the experiment.

I suspect that when you use km in this fashion the experiment version is never used so you only every get version 0, and the alternatives have already been set for that.

I think something like this should work for you:

<% Split::Experiment.all.each do |experiment| %>
  <% km.set(experiment.key, ab_test(experiment.name, *experiment.alternative_names)) %>
<% end %>

@jasonm
Copy link
Author

jasonm commented Oct 3, 2011

Thanks @andrew - makes sense.

@jasonm jasonm closed this as completed Oct 3, 2011
@andrew andrew removed their assignment Nov 17, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants