Sha256: 2cd732e3960db8a5ea81d5a55eff495e85e10f5e60d379da817fc61c3ecf3767
Contents?: true
Size: 1.95 KB
Versions: 12
Compression:
Stored size: 1.95 KB
Contents
--- layout: page title: Welcome to Vanity --- "Vanity":http://github.com/assaf/vanity is an Experiment Driven Development framework for Rails. !images/sidebar_test.png! h3. Reading Order * "2 Minute Demo(A/B Testing with Rails in 5 easy steps)":#intro * "Metrics":metrics.html * "A/B Testing(Everything you need to know)":ab_testing.html * "Using with Rails":rails.html * "Managing Identity":identity.html Also: * "Experiment Driven Development(Introduction to EDD and Vanity)":http://blog.labnotes.org/2009/11/19/vanity-experiment-driven-development-for-rails/ * "Get the code(Official Github repository)":http://github.com/assaf/vanity * "API reference":api/index.html * "Join vanity-talk list":http://groups.google.com/group/vanity-talk * "Contributing to Vanity":contributing.html h3(#intro). A/B Testing with Rails (in 5 easy steps) *Step 1:* Start using Vanity in your Rails application: <pre> Rails::Initializer.run do |config| gem.config "vanity" config.after_initialize do require "vanity" end end </pre> And: <pre> class ApplicationController < ActionController::Base use_vanity :current_user end </pre> *Step 2:* Define your first A/B test. This experiment goes in the file <code>experiments/price_options.rb</code>: <pre> ab_test "Price options" do description "Mirror, mirror on the wall, who's the better price of all?" alternatives 19, 25, 29 metrics :signup end </pre> *Step 3:* Present the different options to your users: <pre> <h2>Get started for only $<%= ab_test :price_options %> a month!</h2> </pre> *Step 4:* Measure conversion: <pre> class SignupController < ApplicationController def signup @account = Account.new(params[:account]) if @account.save track! :signup redirect_to @acccount else render action: :offer end end end </pre> *Step 5:* Check the report: <pre> vanity report --output vanity.html </pre> !images/price_options.png! Read more about "A/B Testing ...":ab_testing.html
Version data entries
12 entries across 12 versions & 4 rubygems