The Loyal application analyzes order data in your store and, based on the outcome of the analysis, it groups your customers into segments depending on their buying behavior. But how does the order data analysis and the subsequent customer segmentation actually work?

When the app is installed, it imports the following data from your store and uses it for further analysis:

  • customer information,

  • order data (not all orders are imported, only those that fulfill the following criteria: the order has a customer ID, it is not cancelled, has been paid, partially paid or partially refunded, is not from the POS sales channel, is not a test order, and has been placed within the last year from the time of importing / syncing).

Each order is grouped by customer, and a normalised value for R(ecency), F(requency) and M(onetary) is calculated. These values are run through a machine learning algorithm (K-means clustering), which partitions the data into one of five clusters. A cluster of 1 to 5 for each RFM part represents the score, i.e. 111 to 555.

A pre-defined score is then used to segment mapping table to label each RFM points range with an appropriate customer segment name.


Since the order data in each store is not the same, the definition of each segment (in terms of the number of orders and the days since last order) also differs from store to store.

Did this answer your question?