Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
I need the median value of a column (whose value is derived from a measure). In every attempt, it is only returning the median of rows that have a value greater than zero.
I have two tables, one is an "employee" table and one an "attendee" table. I have a measure that counts each time an employee is in the attendee table:
Solved! Go to Solution.
Hi,
Please try this measure:
MED Col A = MEDIANX(SUMMARIZE(Employee_M,Employee_M[Employee ID],"EE",[EE Attend]),[EE])
The result shows:
See my attached pbix file.
Best Regards,
Giotto
Hi All,
Thank you for your replies. My numbers are not coming from a static table (as in @Greg_Deckler's .pbix), they are being generated by a counting measure. I would love to post a .pbix file to show this, but it does not look like I can. I have no option to add an attachment to my posts/replies.
Edit: Here are some screen shots that I hope will help explain this further (note that these numbers will be different from my original post).
Here are the two tables:
Here is the relationship:
The visual is a table, with two columns, the first being Employee_M[Employee ID], and the second being this measure:
I should mention that the reason why I am not using a calculated column is that I need to be able to filter by dates.
@J2K Most people use OneDrive or Box or some other file sharing service to share PBIX files.
@Greg_Deckler Here you go:
https://www.dropbox.com/sh/e9nhfa9ct8lvgdt/AABA4QgxXplpOARmOqiK4qlpa?dl=0&preview=MedianDemo.pbix
Again, I appreciate you taking the time to look at these things.
@Greg_Deckler Here you go:
https://www.dropbox.com/sh/e9nhfa9ct8lvgdt/AABA4QgxXplpOARmOqiK4qlpa?dl=0&preview=MedianDemo.pbix
Again, I appreciate that you take the time to look at these things.
Hi Giotto,
Thank you very much. This works perfectly.
Well, all I can say from the information provided is that you are doing something wrong in your calculation. Because MEDIAN and MEDIANX work for your data. See attached PBIX.
User | Count |
---|---|
93 | |
83 | |
77 | |
75 | |
66 |
User | Count |
---|---|
115 | |
105 | |
93 | |
65 | |
60 |