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.
I want to calculate the average number of calls at a given time. For this I have divided all calls into periods of half an hour. Then I want to calculate the average number of calls at a given time. This must be spread over the days. And be calculated from the underlying number of weeks.
Sometimes, however, a phone call comes in at a given time in just 1 week. For example, the period 21:00
Week 1: 5 phone calls, Week 2: -, Week 3: 6, Week 4 - 7: -. Total incoming calls is: 5 + 0 + 6 + 0 + 0 + 0 + 0 = 11. The average is then: 11/7 = 1.5714. However, Power Bi makes it: 5 + 6 = 11. And then on average: 11/2 = 5.5.
The data set used looks like this:
Index | Datum | Tijdstip | Weeknummer |
01 | 05-05-2020 | 21:00 | 19 |
02 | 05-05-2020 | 21:00 | 19 |
03 | 12-05-2020 | 21:00 | 20 |
04 | 26-05-2020 | 21:00 | 22 |
Index Date Time Week number
So this is a total of 4 weeks. While only 3 weeks has been entered. How can I solve this neatly? Because the data set is updated every time, so I want the number of weeks to be calculated automatically.
Solved! Go to Solution.
@Anonymous , Create a date/week table and take week count from there.
Sum(Table[count])/count(Week[WeekNo])
User | Count |
---|---|
15 | |
13 | |
8 | |
6 | |
6 |
User | Count |
---|---|
27 | |
19 | |
12 | |
9 | |
7 |