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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
sigridr
Helper I
Helper I

Average of Rows

Hello, 

 

I have a table of measurements done every hour every day, and I need to find the average per day (row average). 

See picture and table. 

 

 

DatoKl. 1Kl. 2Kl. 3Kl. 4Kl. 5Kl. 6Kl. 7Kl. 8Kl. 9Kl. 10Kl. 11Kl. 12Kl. 13Kl. 14
01.12.202257,4558,5059,7061,0561,2065,2570,3573,3572,0071,4070,5070,9569,9072,15
02.12.202260,4562,2563,9062,8564,6566,6071,2573,2072,0071,8571,2573,9574,5573,95
03.12.202261,8060,4550,7048,1551,4562,1068,2569,1568,8566,1565,4066,9065,1067,80

 

Thanks in advance, 

//Sigrid Average.png

1 ACCEPTED SOLUTION
v-cgao-msft
Community Support
Community Support

Hi @sigridr ,

 

If the number of measurements per day is the same, you may try this.

AVG = 
DIVIDE (
    'Table'[Kl. 1] + 'Table'[Kl. 2] + 'Table'[Kl. 3] + 'Table'[Kl. 4] + 'Table'[Kl. 5] + 'Table'[Kl. 6] + 'Table'[Kl. 7] + 'Table'[Kl. 8] + 'Table'[Kl. 9] + 'Table'[Kl. 10] + 'Table'[Kl. 11] + 'Table'[Kl. 12] + 'Table'[Kl. 13] + 'Table'[Kl. 14] + 'Table'[Kl. 15] + 'Table'[Kl. 16] + 'Table'[Kl. 17] + 'Table'[Kl. 18] + 'Table'[Kl. 19] + 'Table'[Kl. 20] + 'Table'[Kl. 21] + 'Table'[Kl. 22] + 'Table'[Kl. 23] + 'Table'[Kl. 24],
    24
)

For other cases, please consider the advice of tex628.

 

Best Regards,
Gao

Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

How to get your questions answered quickly --  How to provide sample data in the Power BI Forum

View solution in original post

2 REPLIES 2
v-cgao-msft
Community Support
Community Support

Hi @sigridr ,

 

If the number of measurements per day is the same, you may try this.

AVG = 
DIVIDE (
    'Table'[Kl. 1] + 'Table'[Kl. 2] + 'Table'[Kl. 3] + 'Table'[Kl. 4] + 'Table'[Kl. 5] + 'Table'[Kl. 6] + 'Table'[Kl. 7] + 'Table'[Kl. 8] + 'Table'[Kl. 9] + 'Table'[Kl. 10] + 'Table'[Kl. 11] + 'Table'[Kl. 12] + 'Table'[Kl. 13] + 'Table'[Kl. 14] + 'Table'[Kl. 15] + 'Table'[Kl. 16] + 'Table'[Kl. 17] + 'Table'[Kl. 18] + 'Table'[Kl. 19] + 'Table'[Kl. 20] + 'Table'[Kl. 21] + 'Table'[Kl. 22] + 'Table'[Kl. 23] + 'Table'[Kl. 24],
    24
)

For other cases, please consider the advice of tex628.

 

Best Regards,
Gao

Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

How to get your questions answered quickly --  How to provide sample data in the Power BI Forum

tex628
Community Champion
Community Champion

Hi @sigridr

Try the following. 

After loading the data into Power BI Query editor, do the following:

tex628_0-1672838913954.png


Use "Unpivot other columns" while having the date highlighted:

tex628_1-1672838971437.png

Should give you the following:

tex628_2-1672839003618.png


Load the data and add the date and value to the table. 

 

tex628_3-1672839099925.png

Change the aggregation to average:

tex628_4-1672839141708.png

Should give you the following: 

tex628_5-1672839178421.png

 

Hope this helps! 

Br, 
J

 


Connect on LinkedIn

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.

AugPowerBI_Carousel

Power BI Monthly Update - August 2024

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

August Carousel

Fabric Community Update - August 2024

Find out what's new and trending in the Fabric Community.