RFMANALYSIS
Recency, frequency and monetary (RFM) scores from customer data or from transactions.
Syntax
Section titled “Syntax”RFMANALYSIS /RFMVARIABLES RECENCY=var FREQUENCY=var MONETARY=var | ID=var DATE=var MONETARY=var [/SUMMARIES=TOTAL|MEAN|MEDIAN|MAXIMUM] [/REFDATE=value] [/BINNING METHOD=NESTED|INDEPENDENT NUMBINS=5 [RECENCY=n FREQUENCY=n MONETARY=n] TIES=KEEPTOGETHER|RANDOM] [/PRINT=BINS NONE] [/PLOT=HEATMAP HISTOGRAMS BINCOUNTS NONE] [/OUTFILE DATASET=name].Synopsis
Section titled “Synopsis”| Kind | Procedure (reads data, produces output) |
| Body | main /SUBCOMMAND[=] … |
| Changes data | yes, undoable |
| Subcommands | /BINNING, /OUTFILE, /PLOT, /PRINT, /REFDATE, /RFMVARIABLES, /SAVE, /SUMMARIES |
| Menu | Analyze ▸ Direct Marketing |
| Slot: Recency (or transaction date) | 1–1 variable(s); levels: nominal, ordinal, scale; types: numeric |
| Slot: Frequency | 0–1 variable(s); levels: nominal, ordinal, scale; types: numeric |
| Slot: Monetary | 1–1 variable(s); levels: nominal, ordinal, scale; types: numeric |
| Slot: Customer ID (transaction data) | 0–1 variable(s); levels: nominal, ordinal, scale; types: numeric, string |
Specifications
Section titled “Specifications”- RFMVARIABLES: customer data: RECENCY, FREQUENCY, MONETARY; transaction data: ID, DATE, MONETARY
- BINNING: NESTED bins frequency within recency and monetary within both; 2–9 bins per component
- OUTFILE: transaction data only: the new customer dataset (default RFM_Scores)
Examples
Section titled “Examples”RFMANALYSIS /RFMVARIABLES RECENCY=days_since FREQUENCY=orders MONETARY=spend.RFMANALYSIS /RFMVARIABLES ID=customer DATE=order_date MONETARY=amount /SUMMARIES=TOTAL /OUTFILE DATASET=customers.- Scores run from 1 to NUMBINS with the highest for the best customers; RFM_Score = 100R + 10F + M.
- In customer data a date-formatted recency counts later dates as more recent; any other recency variable is read as time since the last purchase.
- Customer data: the four scores are saved to the active dataset.
Related
Section titled “Related”Generated from OrcStat’s command registry and reference. To suggest a change, open an issue.