model_conversion_rpp: Bayesian model that combines conversion estimation and value...

Description Usage Arguments Details Value Author(s)

View source: R/model_conversion_payer.R

Description

Model uses total number of cases and successful cases to estimate conversion based on bernoulli-beta model and for successful cases estimates continuous variable using exponential-gamma model

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
model_conversion_rpp(
  alpha,
  beta,
  success,
  total_sample_size,
  shape,
  rate,
  sum_sample,
  n_post = 1e+05
)

Arguments

alpha

Parameter for prior in bernoulli-beta model representing number of success - 1

beta

Parameter for prior in bernoulli-beta model representing number of fails - 1

success

Actual number of successful cases (payers) in your data.

total_sample_size

Total number of cases in your data.

shape

Parameter for prior in exponential-gamma model representing the number of samples from before - 1

rate

Parameter for prior in exponential-gamma model representing the sum of samples from before

sum_sample

Sum of variable (money) for each successful case.

n_post

Size of sample from posterior distribution

Details

Final result is estimated value for each case (not just converted cases). Motivation is when you have some percent of users that spend money and others that spend no money. First we estimate conversion to payers rate, and for payers estimate revenue per payer (rpp). Final posterior distribution is multiple of these two posterior distributions and is representing revenue per user (rpu).

Check model_bernoulli_beta and model_exponential_gamma for details regarding each model.

Value

List of 3 posterior distributions: post_conv representing conversion rate (success rate) from bernoulli-beta model, post_rpp representing value of variable (money) per successful case from exponential-gamma model, post_rpu representing value of variable per each case (money per all cases), post_rpu = post_conv * post_rpp

Author(s)

Elio Bartoš


eliobartos/bayeselio documentation built on Feb. 5, 2021, 2:16 p.m.