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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
gaccho_na
New Member

How to create composition ratio in powerBI ---2

Hello,

I want to display output Matrix B from data table A.

Too difficult for me.

Please Help me !

 

data table A

DateDIVAttvalue
2020/04Net SalesActual600,000
2020/04Net SalesPlan590,000
2020/04Cost of SalesActual300,000
2020/04Cost of SalesPlan310,000
2020/04Gross ProfitActual300,000
2020/04Gross ProfitPlan280,000
2020/04SGA expensesActual120,000
2020/04SGA expensesPlan120,000
2020/04Operating incomeActual180,000
2020/04Operating incomePlan160,000
2020/05Net SalesActual800,000
2020/05Net SalesPlan810,000
2020/05Cost of SalesActual390,000
2020/05Cost of SalesPlan400,000
2020/05Gross ProfitActual410,000
2020/05Gross ProfitPlan410,000
2020/05SGA expensesActual125,000
2020/05SGA expensesPlan130,000
2020/05Operating incomeActual285,000
2020/05Operating incomePlan280,000
2020/06Net SalesActual500,000
2020/06Net SalesPlan490,000
2020/06Cost of SalesActual260,000
2020/06Cost of SalesPlan250,000
2020/06Gross ProfitActual240,000
2020/06Gross ProfitPlan240,000
2020/06SGA expensesActual120,000
2020/06SGA expensesPlan130,000
2020/06Operating incomeActual120,000
2020/05Operating incomePlan110,000

 

output Matrix B
Slicer : Date = 2020/04

 Plan Actual 
 TTL Value Plancomposition ratioTTL Value Actualcomposition ratio
Net Sales590,000100.0%600,000100.0%
Cost of Sales310,00052.5%300,00050.0%
Gross Profit280,00047.5%300,00050.0%
SGA expenses120,00020.3%120,00020.0%
Operating income160,00027.1%180,00030.0%
1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@gaccho_na , You need two measures

 

M1 = sum(Data[Value])

% = Divide(sum(Data[Value]), calculate(sum(Data[Value]), filter(allselected(Data[DIV]), Data[DIV] = "Net Sales" )))

 

Please find the attached file after signature

 

 

View solution in original post

1 REPLY 1
amitchandak
Super User
Super User

@gaccho_na , You need two measures

 

M1 = sum(Data[Value])

% = Divide(sum(Data[Value]), calculate(sum(Data[Value]), filter(allselected(Data[DIV]), Data[DIV] = "Net Sales" )))

 

Please find the attached file after signature

 

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors