Last active
February 13, 2020 17:06
-
-
Save lucdangelis/93204817276c192b3cd51d5f1050a097 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pandas as pd | |
import numpy as np | |
from lifetimes.utils import * | |
from lifetimes import BetaGeoFitter | |
from lifetimes.plotting import plot_probability_alive_matrix, plot_frequency_recency_matrix | |
from lifetimes.generate_data import beta_geometric_nbd_model | |
import matplotlib.pyplot as plt | |
from lifetimes.plotting import plot_calibration_purchases_vs_holdout_purchases, plot_period_transactions,plot_history_alive | |
bgf = BetaGeoFitter() | |
bgf.fit(data['frequency'], data['recency'], data['T']) | |
mbgf.summary |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
When I'm trying to execute this part, I'm getting the error related to
mbgf
, I think it's not declared before.