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
cbtekrony
Resolver I
Resolver I

Projections Using Avg Growth %

I am computing future growth with this DAX:

 

PROJECTED GRWTH  AVG YOY CHANGE=
VAR vCurYear =
CALCULATE ( YEAR ( MAX ( 'Table'[Process Date] ) ), ALL(' Table') )
 
VAR vCurYearSales =
CALCULATE ( SUMX ( 'Table', 'Table'[ACV+YTD Est.DD] ), 'Calendar Table'[Year] = vCurYear )
 
VAR vYearIncrement =
MAX ( 'Calendar Table'[Year] ) - vCurYear
 
VAR vProjGrowth =
vCurYearSales * POWER ( 1 + [YoY Avg. Change], vYearIncrement )
 
VAR vResult =
IF ( MAX ( 'Calendar Table'[Year] ) <= vCurYear, BLANK (), ROUND ( vProjGrowth, 0 ) )
 
RETURN
vResult
 
The forecast result I'm getting is the total of vCurYearSales  for each future year. If I plug in the "hard" number instead of my measure [YOY Avg Change] above, I get the correct forecast.  But of course, the point of DAX is to have dynamic results. 
Why can't I use my measure [YOY Avg Change] to compute this?
 

Power BI.jpg

1 ACCEPTED SOLUTION
cbtekrony
Resolver I
Resolver I

Solved! I sat on it for a few months and did a quick Google yesterday. I needed to use this particular calculation to figure out and keep dynamic the average percent change over time

VAR vGrowthRate =
AVERAGEX(
FILTER(ALLSELECTED('Calendar Table'),
'Calendar Table'[Date] <= MAX('Calendar Table'[Date])),
[YoY Change])

View solution in original post

2 REPLIES 2
cbtekrony
Resolver I
Resolver I

Solved! I sat on it for a few months and did a quick Google yesterday. I needed to use this particular calculation to figure out and keep dynamic the average percent change over time

VAR vGrowthRate =
AVERAGEX(
FILTER(ALLSELECTED('Calendar Table'),
'Calendar Table'[Date] <= MAX('Calendar Table'[Date])),
[YoY Change])
v-kelly-msft
Community Support
Community Support

Hi @cbtekrony ,

 

Could you pls provide a sample .pbix file for test?Remember to remove confidential information inside.

 

Best Regards,
Kelly

Did I answer your question? Mark my post as a solution!

 

 

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.