cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
whereismydata Helper I
Helper I

Actuals and forecast value in one measure

Hi 🙂

 

I'm looking for a solution to display actuals and forecast values in one measure/column. I then want to display this measure/column in a linechart (x axis = Date; y= Value).

All I have are the actual values with a timestamp, what I want is to calculate an average value multiplied by an parameter (which will be a slicer, so the viewer can adjust the increase)

 

ValueDate
Source
102019-09-02
Actual
202019-09-03
Actual
172019-09-04Forecast
172019-09-04Forecast
.........
172019-12-31Forecast

 

What I have:

ValueDate
102019-09-02
202019-09-03

 

My first approach was to calculate a tally table in m query to get all dates for the current year

= List.Dates(#date(Date.Year(DateTime.LocalNow()), 1, 1), 365, #duration(1, 0, 0, 0))

I then join both tables to get this table:

ValueDateDate_joined
102019-09-022019-09-02
202019-09-032019-09-03
  2019-09-04
  ...
  2019-12-31

 

With DAX I created a calculated column to fill in the blanks with the average of [value] * the value from the slicer (Adjustment Value).  It does work with my dummy data to fill in the average amount but the '*Adjustment[Adjustment Value])' section is beeing ignored.

IF(DummyData[Date]=DummyData[Date_joined];DummyData[Value];(DummyData[Average]*Adjustment[Adjustment Value]))
ValueDateDate_joinedCombined
102019-09-022019-09-0210
202019-09-032019-09-0320
  2019-09-0415
  ...15
  2019-12-3115

 

 

 

As always, I think there possibly is an easy solution I'm not aware of.

 

Thanks in advance for any guidance 🙂

 

 

You can download the file here: Link

 

 

Sources I tried but couldn't get to work:

https://www.sqlbi.com/articles/showing-actuals-and-forecasts-in-the-same-chart-with-power-bi/

https://community.powerbi.com/t5/Desktop/Revenue-forecast-from-actual-sales/m-p/280437#M124944

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Re: Actuals and forecast value in one measure

Hi @whereismydata 

 

I think it's cozed by you didn't set the relationship between DummyData table with Adjustment table.  The adjustedaverage value could not be defined correctly.

 

When I rebuild the adjustment table with adding "Person" column, and manage the relationship. the [Combined] column show directly.

 

 

Community Support Team _ Dina Ye
If this post helps, then please consider Accept it as the solution to help the other members find it more
quickly.

View solution in original post

4 REPLIES 4
Community Support
Community Support

Re: Actuals and forecast value in one measure

Hi @whereismydata 

 

Would you mind share me your dummy pbix? that would be easier for us to search in depth.

 

Community Support Team _ Dina Ye
If this post helps, then please consider Accept it as the solution to help the other members find it more
quickly.
whereismydata Helper I
Helper I

Re: Actuals and forecast value in one measure

Hi @v-diye-msft ,

 

I uploaded the file; also when creating this dummy environment filling the blanks with an average value works. So there seems to be an issue with my real data. But the multiplication with the what if parameter does not work. Maybe you'll have an idea whats wrong.

 

also it would be interesting to know if there is an easier solution for my problem.

 

all the best and thank you!

Community Support
Community Support

Re: Actuals and forecast value in one measure

Hi @whereismydata 

 

I think it's cozed by you didn't set the relationship between DummyData table with Adjustment table.  The adjustedaverage value could not be defined correctly.

 

When I rebuild the adjustment table with adding "Person" column, and manage the relationship. the [Combined] column show directly.

 

 

Community Support Team _ Dina Ye
If this post helps, then please consider Accept it as the solution to help the other members find it more
quickly.

View solution in original post

whereismydata Helper I
Helper I

Re: Actuals and forecast value in one measure

Hi @v-diye-msft 

 

thank you very much for your reply and the attached file. I'll take a look into it today.

 

best

Helpful resources

Announcements
New Ranks Launched March 24th!

New Ranks Launched March 24th!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power BI Community!

‘Better Together’ Contest Finalists Announced!

‘Better Together’ Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

Arun 'Triple A' Event Video, Q&A, and Slides

Arun 'Triple A' Event Video, Q&A, and Slides

Missed the Arun 'Triple A' event or want to revisit it? We've got you covered! Check out the video, Q&A, and slides now.

Join THE global Microsoft Power Platform event series.

Join THE global Power Platform event series.

Attend for two days of expert-led learning and innovation on topics like AI and Analytics, powered by Dynamic Communities.

Community Summit North America

Community Summit North America

Innovate, Collaborate, Grow. The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Top Kudoed Authors