This codebase has moved to "archived-mode". We won't be adding new features, improvements, or even answering issues in this codebase.
A project has emerged as a successor to lifetimes, PyMC-Lab/PyMC-Marketing, please check it out!
Measuring users is hard. Lifetimes makes it easy.
Introduction
Lifetimes can be used to analyze your users based on a few assumption:
Users interact with you when they are "alive".
Users under study may "die" after some period of time.
I've quoted "alive" and "die" as these are the most abstract terms: feel free to use your own definition of "alive" and "die" (they are used similarly to "birth" and "death" in survival analysis). Whenever we have individuals repeating occurrences, we can use Lifetimes to help understand user behaviour.
Applications
If this is too abstract, consider these applications:
Predicting how often a visitor will return to your website. (Alive = visiting. Die = decided the website wasn't for them)
Understanding how frequently a patient may return to a hospital. (Alive = visiting. Die = maybe the patient moved to a new city, or became deceased.)
Predicting individuals who have churned from an app using only their usage history. (Alive = logins. Die = removed the app)
Predicting repeat purchases from a customer. (Alive = actively purchasing. Die = became disinterested with your product)
Probably, the seminal article of Non-Contractual CLV is Counting Your Customers: Who Are They and What Will They Do Next?, by David C. Schmittlein, Donald G. Morrison and Richard Colombo. Despite it being paid, it is worth the read. The relevant information will eventually end up in this library's documentation though.