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

Regular Visitor

## How to transform the excel input into a summary table

Hi Team,

I'm new to Power BI and getting input in below format.

Class                              Colour              Count

 Class1 Orange 4 Class1 Orange 6 Class1 Red 5 Class2 Blue 4 Class2 Yellow 6 Class2 Blue 2

from the above I'm planning to generate a new table but not sure how can i achieve. Can you guide me how can i generate a summary table like below ,

and also

if i need to use Mesaure can you tell me how i can compare the class , colour to get the abg count?

Class                     Colour      Avg count

 Class1 Orange 5 Class1 Red 5 Class2 Blue 3 Class2 Yellow 6
1 ACCEPTED SOLUTION
Community Support

Hi @krishnavzm123,

It sounds like a common measure expression calculate with multiple aggregates requirements.

If that is the case, you can create a measure formula with summarize function to aggregate and use iterator function AVERAGEX get the average of count of records.

``````formual =
AVERAGEX (
SUMMARIZE (
ALLSELECTED ( Table ),
[Class],
[Colour],
"cColor", COUNTA ( Table[Colour] )
),
[cColor]
)``````

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.
1 REPLY 1
Community Support

Hi @krishnavzm123,

It sounds like a common measure expression calculate with multiple aggregates requirements.

If that is the case, you can create a measure formula with summarize function to aggregate and use iterator function AVERAGEX get the average of count of records.

``````formual =
AVERAGEX (
SUMMARIZE (
ALLSELECTED ( Table ),
[Class],
[Colour],
"cColor", COUNTA ( Table[Colour] )
),
[cColor]
)``````

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

## Helpful resources

Announcements

#### 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.

#### Join our Community Sticker Challenge

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

#### Power BI Monthly Update - July 2024

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

#### Fabric Community Update - July 2024

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

Top Solution Authors
Top Kudoed Authors