From 882fffaefa65aea73254a7bf44b5f6c3b0aa0043 Mon Sep 17 00:00:00 2001 From: Idrissa Konkobo <93009177+konkinit@users.noreply.github.com> Date: Thu, 10 Aug 2023 15:21:51 +0200 Subject: [PATCH] Update beta_geo.py Correcting the expected alive probability theoretical formula --- pymc_marketing/clv/models/beta_geo.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pymc_marketing/clv/models/beta_geo.py b/pymc_marketing/clv/models/beta_geo.py index fc0800ae5..a193ac65f 100644 --- a/pymc_marketing/clv/models/beta_geo.py +++ b/pymc_marketing/clv/models/beta_geo.py @@ -294,13 +294,13 @@ def expected_probability_alive( derivation of the closed form solution is available in [2]. .. math:: - P\left\text{alive} \mid x, t_x, T, r, \alpha, a, b\right) + P\left( \text{alive} \mid x, t_x, T, r, \alpha, a, b \right) = 1 \Big/ \left\{ 1 + \delta_{x>0} \frac{a}{b + x - 1} \left( - \frac{\alpha + T}{\alpha + t_x}^{r + x} - \right)^{r x} + \frac{\alpha + T}{\alpha + t_x} + \right)^{r + x} \right\} """ T = np.asarray(T)