cancel
Showing results for
Did you mean:

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Frequent Visitor

## Trendline of Percent Increase from Starting Year (3% Annually)

Hello hivemind,

I am seeking to incorporate DAX measure solution to superimpose a dynamic trendline that takes the starting year value and projects a 3% increase annually from that base year.
Any insight will be appreciated.

1 ACCEPTED SOLUTION
Community Support

My sample:

1. Create a calculated column as follows

``Year = YEAR([Date])``

2. Create a measure as follows

``````Measure =
VAR _minYear = CALCULATE(MIN([Year]), ALL('Table'))
VAR _minSum = CALCULATE(SUM('Table'[value]), FILTER(ALL('Table'), [Year] = _minYear))
VAR _diff = MAX([Year]) - _minYear
VAR _result = _minSum + _minSum * _diff * 0.03
RETURN
_result``````

Result:

Select the Line and clustered Column chart visualization, and then place the measure into the Line y-axis

Best Regards,
Yulia Xu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

3 REPLIES 3
Community Support

My sample:

1. Create a calculated column as follows

``Year = YEAR([Date])``

2. Create a measure as follows

``````Measure =
VAR _minYear = CALCULATE(MIN([Year]), ALL('Table'))
VAR _minSum = CALCULATE(SUM('Table'[value]), FILTER(ALL('Table'), [Year] = _minYear))
VAR _diff = MAX([Year]) - _minYear
VAR _result = _minSum + _minSum * _diff * 0.03
RETURN
_result``````

Result:

Select the Line and clustered Column chart visualization, and then place the measure into the Line y-axis

Best Regards,
Yulia Xu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Frequent Visitor

Thank you Yulia Xu; you have been very helpful.
This works brilliantly for the example I posted.
I subsequently added a group slicer to this report and tweaked your original DAX to dynamically reset the starting comparison value totals as slicer groups are selected:

Frequent Visitor