The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
Hi Guys, Im stuck on the below. Im guessing im overthinking this.
So I have created a measure which gives me a total average percentage of increase or decrease. Example:
Im comparing students attendance against 2 time frames. 'this part works fine'
Time frame 1 = 70% average over 20 students
Time frame 2 = 90% average over the same 20 students
giving me an average increase of 28.5%
My measure called (attandance_variance) gives my 28.5% when comparing the dynamic time frames selected.
I now need to workout a hit rate within this measure. So I need to find out how many of the 20 students improved their attendance vs the previous time frame.
I was hoping I could use this measure within a new measure and use the count function and filter it by scores over above 0. but this does not seem to be working for me. Example:
Solved! Go to Solution.
@TFTF_BI , Try like
Count_Students_Attendance_Improved =
COUNTX(FILTER(values(Students[school_student_id]),[attendance_variance]>1),[school_student_id])
TO filter measure you need push a group by , values is doing same here
Hi TFTF_BI,
Try changing the table in the filter context to the Students table. Because that is the table that you would like to filter, not Attendance_Measures.
Count_Students_Attendance_Improved =
CALCULATE(
DISTINCTCOUNT(Students[school_student_id]),
FILTER(
'Students',
[attendance_variance]>1
)
)
This is assuming the column [school_student_id] is distinct and the attendance_variance measure works with single students.
@TFTF_BI , Try like
Count_Students_Attendance_Improved =
COUNTX(FILTER(values(Students[school_student_id]),[attendance_variance]>1),[school_student_id])
TO filter measure you need push a group by , values is doing same here
Awesome, Would it be similer if I wanted to return the average increase for those have increased?