Customer Segmentation Pattern

Hey Guys,

I have used the the Customer Segmentation Pattern from the Advanced Analytics in Power BI Class with great success in several projects now. However, I’ve run into an issue now and have found myself stumped.

I’m loading data from a CVS file and it has 4 fields:

  1. Order_ID
  2. Location
  3. DaysActive
  4. SalesPrice

I’d like to use the Segmentation Pattern on the SalesPrice and DaysActive fields so that I can group the orders by amount of time the orders were active for example “1 to 10 Days”, “11 to 20 Days” etc. Also I’d like to use the Segmentation Pattern on SalesPrice field to group the orders by their sale price amount.

The example in the class uses a star schema but for this data set it will simply be a flat table. The other difference from the example in the class is that I’m adding Sort by column to the Look Up table so that the data can be sorted properly in slicers and tables.

I can only get one calculated column to work at a time. If I add in the Sale Price Range calculated column I get a Circular Dependency Error when I try to add in the Sales Price Range Sort by calculated column.

I have almost the exact same pattern working in other files the only difference is that the others use a star-schema.

Should I be taking a different approach with this?

I’m uploading the file. The file has the one calculated column that is working properly and also the 3 others that are generating an error.

Any help is greatly appreciated.

Thanks!!!

Slicer Sort Issue.pbix (85.6 KB)

Hi,
I have added your file with some amendments and a table with measures. This should help you on your way. Use measures instead of calculated columns, where you can. Should you wish to add a slicer with the bin ranges, then add a calculated column in orders using the SWITCH function with corresponding breaks.
Your SP range looks inconsistent <50K whereas the min max shows 0-5000.
Hope this helps.

Slicer Sort Issue Response.pbix (109.2 KB)

Paul

Enterprise%20DNA%20Expert%20-%20Small

Thanks for you help Paul!!!

I ended up putting a solution together using M instead of DAX last night.

Here’s the file using M:

Slicer Sort Issue - M.pbix (93.3 KB)

Thanks, many ways to solve this.
I am curious to find if, with larger files, M is better than a DAX formula in this case.

Paul

Enterprise%20DNA%20Expert%20-%20Small