Measuring customer retention using cohort analysis in R
Within the e-commerce field, customer retention metrics can be considered crucial for several reasons. Among these, the virtual absence of a barrier to entry for competitors in the virtual arena makes online sellers very willing to build an enduring relationship with their customers.
This recipe gives you a straightforward way to compute retention metrics within the R environment.
From the possible methods available for these tasks, we will use one from the family of cohort methods.
In this method, customers are divided into homogenous groups (that is, cohorts) that share relevant segmentation attributes, such as sex or age.
Purchases made by those groups are monitored monthly over a period of time, and a retention rate is calculated each month using the following formula:
retention rate = (number of customers purchasing in a given month)/(number of customers within the cohort at the starting point)
Getting ready
This recipe is not going...