Session Ready
Exercise

Adding a prior to the model

You're not so sure that your ad will get clicked on exactly 10% of the time. Instead of assigning proportion_clicks a single value you are now going to assign it a large number of values drawn from a probability distribution.

Instructions 1/4
undefined XP
  • 1
  • 2
  • 3
  • 4

For now, we are going to assume that it's equally likely that proportion_clicks could be as low as 0% or as high as 20%. These assumptions translate into a uniform distribution which you can sample from in R like this:

x <- runif(n = n_samples, min = 0.0, max = 0.2)
  • Replace the single value that is assigned to proportion_clicks with n_samples samples produced by runif as above.