Forecast future purchases and spend per customer using BG/NBD + Gamma‑Gamma; build cohorts and target high‑value segments
Calculates Recency, Frequency, and Monetary value from transaction history, with simplified BG/NBD modeling for probability alive estimates.
Simplified Gamma-Gamma approach using weighted average between individual and population mean spending, discounted to present value.
Automatic segmentation into Low/Medium/High value groups based on CLV quantiles, with holdout validation when available.
Your data needs customer_id_column, transaction_date_column, transaction_value_column, plus a calibration_end date to split training/holdout periods.
Data format: Transaction-level data with one row per purchase. The algorithm calculates RFM metrics, estimates probability alive, and projects future transactions.
Minimum requirements: Customers need repeat transactions for accurate modeling. At least 6-12 months of history recommended.
What you get: CLV per customer, probability alive scores, expected future transactions, customer segments, validation metrics (MAE/RMSE) if holdout data exists.
From historical orders to calibrated LTV
Aggregates transactions per customer to compute Recency (days since last purchase), Frequency (repeat transactions), and Monetary value (average spend).
Simplified BG/NBD estimates probability alive based on recency patterns, while Gamma-Gamma predicts future transaction values using frequency-weighted averages.
Calculates discounted CLV using expected transactions × predicted value × discount factor, then segments customers into value tiers.
CLV focuses acquisition and retention on customers who will generate the most value—improving ROI and budgeting accuracy.
Use LTV to prioritize channels, set bids and CPA targets, and tailor lifecycle programs by predicted value. Cohort views help explain growth and retention over time.
Note: BG/NBD assumes purchase probability and churn are stationary; Gamma‑Gamma assumes monetary value is independent of purchase frequency. Monitor for regime shifts and re‑estimate as behavior changes.
Forecast customer value and target high‑impact segments
Read the article: BG/NBD LTV