I have Sampledata table showing price changes,
A matrix has been created showing price for each month.
I also have a table that shows yearly CPI.
What I would like is to highlight the prices on table one where the PRICE CHANGE is 1st table has a higher percent change than the previous year CPI.
For example, MODEL #1 in the first table would have JAN 2019 shaded because it is a price increase of 13.33% and 2018 CPI AVG is 1.910%. Also, MARCH 2019 would be shaded because it is a price increase of 23.53%, again, above the 2018 AVG CPI of 1.910.
Hope this makes sense.
Hi @pbeeyeqs ,
Maybe you can create your measures like so:
Effective Price of the previous month = VAR a = MAX ( DatesTable[Date].[MonthNo] ) - 1 VAR b = MAX ( DatesTable[Date].[Year] ) - 1 RETURN IF ( a <> 0, CALCULATE ( MAXX ( DatesTable, [EFFECTIVE PRICE] ), FILTER ( ALL ( DatesTable ), a = DatesTable[Date].[MonthNo] && b + 1 = DatesTable[Date].[Year] ) ), CALCULATE ( MAXX ( DatesTable, [EFFECTIVE PRICE] ), FILTER ( ALL ( DatesTable ), b = DatesTable[Date].[Year] && DatesTable[Date].[MonthNo] = 12 ) ) )
PRICE CHANGE = DIVIDE ( [EFFECTIVE PRICE] - [Effective Price of the previous month], [Effective Price of the previous month] )
If Price Change is higher than previous year = IF ( [PRICE CHANGE] > MAX ( 'CPI YRLY AVG'[AVG] ), 1, 0 )
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
How have you calculated the CPI (%) change as 1.910% for 2018. If i apply a filter on 2019 in the CPI Table, the simple average is 254.72. If i apply a filter on 2018 in the same table, the simpel average is 251.10. The % change should be 1.44%. Please clarify.
The CPI is yearly avg, not monthly avg for the year.
Take (DEC 2018 - DEC 2017) / DEC 2017
(251.233 - 246.524) / 246.524 = 1.91%
Sorry I didn't clarify.
Thank you for clarifying. The Growth in effective price (%) in January 2019 is 13.33%. In January 2019, the Growth in CPI (%) should be
=(Jan 2019 CPI - Jan 2018 CPI)/Jan 2018 CPI
This figure is 1.55%.
Since 13.33% > 1.55%, the 13.33% cell should be coloured. Is my understanding correct?
Yes, for MODEL #1 the price change is 13.33% in Jan 2019, so that cell should be colored. And, March 2019 would be colored because the increase is 23.53%, which is also greater than the 1.55%
Another example, Product #7, July 2018 is colored because the price increase is 100% and that is greater than the CPI of
(JAN 2018 - JAN 2017) / JAN 2017
Why should the Growth in Effective price in July 2018 be compared with the growth in CPI for January. The coparison should be with the figure that we get by the following equeation
=(JULY 2018 - JULY 2017) / JULY 2017
OK - had a response then had a discussion regarding your point: if you think I should add as new question, I'm fine with that.
So, say we choose MODEL #1. We want to pick our timeline, MM/YY to MM/YY
We would want 2 results
1) What is the percent price change of MODEL #1 during that time period
2) What is the percent price change of the CPI during that same period
Ultimately, what I would be doing next is charting the 2 percentages over time (monthly) on the same graph.
I am confused now. For 4/5 months, please show me the exact result you are expecting with an explanation so that i can tally my answers with your expected results.
Check out the News & Announcements to learn more.
Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.
Microsoft received the highest score of any vendor in both the strategy and current offering categories.