Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
BadAtDAX
Regular Visitor

Help with calculating percentiles of values from a measure that uses columns from two data sources?

Hi all,

 

I'm struggling with the DAX for a percentile calculation measure.  In my Item data source I have (among other columns) Item ID and Manufacturing Location.

In my Defect data source I have (among other other columns) Defect ID, Defect Type, and Item ID.

I made a measure for defect percentage as Defect % = DISTINCTCOUNT('Defect'[Item ID]) / DISTINCTCOUNT('Item'[Item ID]).

My goal is to find the percentile of each manufacturing location's Defect % so that I can then calculate the mean and standard deviations of the distribution of Defect % for other calculations.

I'm having a lot of trouble with the DAX for this, so any help is greatly appreciated.

3 REPLIES 3
Mahesh0016
Super User
Super User

@BadAtDAX can you please share expected output in table for more understanding.Thank You!!

Sure, my expected output is as follows:

 

 

Manufacturing Location       Defect %     Defect % Percentile
New York2%0.00%
Los Angeles6%60.00%
San Francisco2%0.00%
Chicago8%100.00%
Philadelphia7%80.00%
Detroit3%40.00%

 

Hi, @BadAtDAX 

 

Can you provide some of the source data, or explain how the expected output was obtained?

 

Best Regards

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.