Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Good day,
I am trying to calculate the average total count of "Location Codes" per month.For instance, in the below chart the average count per month is 3.5
| Location Code | Creation Date |
| 1 | 7/22/2020 |
| 2 | 7/22/2020 |
| 3 | 8/22/2020 |
| 4 | 8/23/2020 |
| 5 | 8/24/2020 |
| 6 | 8/25/2020 |
| 7 | 9/1/2020 |
| 8 | 9/2/2020 |
| 9 | 9/3/2020 |
| 10 | 9/4/2020 |
| 11 | 10/1/2020 |
| 12 | 10/2/2020 |
| 13 | 10/3/2020 |
| 14 | 10/4/2020 |
Solved! Go to Solution.
@dw700d try this
Avg =
AVERAGEX ( VALUES ( Table[Month] ), CALCULATE ( COUNTROWS ( Table ) ) )
Assuming you have a month column in your table, or I would recommend adding a date dimension in your model, and then use a month column from that dimension, you can simply add one as per my blog post.
Check my latest blog post Compare Budgeted Scenarios vs. Actuals I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
@dw700d try this
Avg =
AVERAGEX ( VALUES ( Table[Month] ), CALCULATE ( COUNTROWS ( Table ) ) )
Assuming you have a month column in your table, or I would recommend adding a date dimension in your model, and then use a month column from that dimension, you can simply add one as per my blog post.
Check my latest blog post Compare Budgeted Scenarios vs. Actuals I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
@dw700d it should be a simple measure
Avg = AVERAGE ( Table[Location] )
Put month and avg in a table visual to see the result.
Check my latest blog post Compare Budgeted Scenarios vs. Actuals I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
thanks for your help @parry2k , but my location code column is text and I am trying to calculate the count of that text column. How do I calculate the average count of a text column?
@dw700dcan you please explain how the average count per month is 3.5.
This is what I see
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.