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

Reply
StidifordN
Helper III
Helper III

Calculated Graph line +5% from existing value

Morning all, 

 

Looking to have a 'Target' line included, that is a calculated value 5% higher than the 'Previous Year' figures.  What is the best way to achieve this?

The spend figure is a cumulative figure - formula below.

Total Spend AU Cumulative = 
CALCULATE(
SUM(APAll[NET_AMOUNT_AU]),
FILTER(ALLSELECTED(APAll[ReportingMonth]),
ISONORAFTER(APAll[ReportingMonth],MAX(APAll[ReportingMonth]),DESC)))

 

The legend formula is below

CY Graph Format = 
Switch(True(),
YEAR(APAll[PTRN_POSTED])=YEAR(TODAY()),"Current Year",
YEAR(APAll[PTRN_POSTED])=YEAR(TODAY())-1,"Previous Year","")

 

GraphImage1.png

 

Cheers 🙂

1 REPLY 1
amitchandak
Super User
Super User

@StidifordN , Create measure for this year vs last year as with legend you will not be able add thrid line

 

You can have a measure like [previous year] *1.05

 

if you have for previous yeat with help from date table, you can get

 

CALCULATE(SUM(Sales[Sales Amount]),dateadd('Date'[Date],-1,Year))

 

Why Time Intelligence Fails - Powerbi 5 Savior Steps for TI :https://youtu.be/OBf0rjpp5Hw
https://amitchandak.medium.com/power-bi-5-key-points-to-make-time-intelligence-successful-bd52912a5b...
To get the best of the time intelligence function. Make sure you have a date calendar and it has been marked as the date in model view. Also, join it with the date column of your fact/s. Refer :radacad sqlbi My Video Series Appreciate your Kudos.

Helpful resources

Announcements
July 2024 Power BI Update

Power BI Monthly Update - July 2024

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

July Newsletter

Fabric Community Update - July 2024

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

Top Solution Authors