Supplies are limited. Contact info@espc.tech right away to save your spot before the conference sells out.
Get your discountScore big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount
Hello Everyone! I am having an issue when it comes to using the DAX Function for TOPN and "Others".
The DAX Code is below for reference;
What I am trying to do is:
1. Have a List of Top 25 Billing Providers by Billed Amount, Allowed Amount, and Discount Percentage
2. Have a "others" subcategory to account for all other billing providers outside the top 25 list
3. The Discount should be composite and be calculated as Discount = 1 - (Allowed Amount / Billed Amount)
The issue is with the last step. Each Time I try calculating the discount I will get all of the providers outside the Top 25 Listed (pictures provided below). When I simply do the calculation Allowed Amount / Billed Amount I will get the function to group the way I wanted (Top 25 + "Others"). But for whatever reason when I do the composite it will result in retrieving everything outside the Top 25. I feel like I am so close! What am I doing wrong?
"Billing Provider Name",
CALCULATE ( (1-[Measure Discount]), KEEPFILTERS ( TopProducts ) ),
Here 1 is a constant. Whenever a product is not in the top products, this calulation retruns 1 because 1 is always there and nothing is subtracted if products are not in top products. This is what you see in your visual.
Proposed changes:
1. Change measure [Discount] to
Discount = DIVIDE (Billed Amount - Allowed Amount, Billed Amount)
2. Replace every occurence of
1-[Measure Discount]
with
[Measure Discount]
User | Count |
---|---|
12 | |
12 | |
8 | |
8 | |
6 |
User | Count |
---|---|
27 | |
19 | |
14 | |
11 | |
7 |