Forum Discussion
Deriving Customer churn from data alone
- 9 years ago
This is quite complicated. I don't know if it can be done in DAX, but I created something in Power Query in this Excel file.
(shared from my OneDrive).
With regard to your remark "another day (say End of Previous month)" I created:
a parameter EndOfPeriodUnit as one of the values from the list PeriodUnits with days, weeks, months, quarters, years
a parameter NumberOfPeriods for the number of periods to go back
a function GetPreviousDate to get the previous date, based on a date (Date_Worked) and the 2 parmeters mentioned above).
You can edit the parameters via the option "Manage Parameters" - "Edit Parameters" on the Home tab of the Query Editor.
After that, you need to refresh the query to get the results based on the new parameter values.
Query CustomerChurn should do what you want it to; I added some explanatory comments; you can see these in the Advanced Editor.
Probably this is not yet the final result. If you think we're on the right way and if you are confident that you will be able to manage it yourself (eventually), then we can proceed and apply any refinements.
This is quite complicated. I don't know if it can be done in DAX, but I created something in Power Query in this Excel file.
(shared from my OneDrive).
With regard to your remark "another day (say End of Previous month)" I created:
a parameter EndOfPeriodUnit as one of the values from the list PeriodUnits with days, weeks, months, quarters, years
a parameter NumberOfPeriods for the number of periods to go back
a function GetPreviousDate to get the previous date, based on a date (Date_Worked) and the 2 parmeters mentioned above).
You can edit the parameters via the option "Manage Parameters" - "Edit Parameters" on the Home tab of the Query Editor.
After that, you need to refresh the query to get the results based on the new parameter values.
Query CustomerChurn should do what you want it to; I added some explanatory comments; you can see these in the Advanced Editor.
Probably this is not yet the final result. If you think we're on the right way and if you are confident that you will be able to manage it yourself (eventually), then we can proceed and apply any refinements.
- lutur9 years agoFrequent Visitor
Thanks Marcel
This would take me a couple of days to understand. Let me get back to you..