Average days per month / transaction for a forecast

Good day
I am trying to calculate a forecast of the metric tons that will move in the organization, from the forum I found some code that I have used in my model, but I encounter a problem
I am making the forecast based on the days of the month, which for this example (April) would apply 30 days.
But not all business units (Segments) operate every day of the month, case the COPE business unit in the data I have given me an average of 15 days

So, when I forecast this business unit it does so on current average * 30 giving a very high figure when it should be for 15 days

I tried to calculate the average of days and replace it with the days of the month, but since I am filtering or eliminating the month of April, I cannot make it work.

I am concerned that when I want to go to a deeper level, I have no idea how to calculate the average
for example, if you had the levels of:
Segment
Terminal
Customer
Service
attached the pbix.
thanks for your help
JdC

Forecast OSI’s v2.pbix (2.8 MB)

Hi @Jesus74, we aim to consistently improve the topics being posted on the forum to help you in getting a strong solution faster. While waiting for a response, here are some tips so you can get the most out of the forum and other Enterprise DNA resources.

  • Use the forum search to discover if your query has been asked before by another member.

  • When posting a topic with formula make sure that it is correctly formatted to preformated text </>.

  • Use the proper category that best describes your topic

  • Provide as much context to a question as possible.

  • Include demo pbix file, images of the entire scenario you are dealing with, screenshot of the data model, details of how you want to visualize a result, and any other supporting links and details.

I also suggest that you check the forum guideline How To Use The Enterprise DNA Support Forum. Not adhering to it may sometimes cause delay in getting an answer.

Have you looked at Sam’s training on forecasting? I’d suggest formatting your data in a suitable form then apply the techniques Sam taught on the tutorial to this problem:

Hi thanks for your response
I watched the videos that were related to making a budget or forecast, but I didn’t find something that I could use for the problem I have, in fact, part of the code is from another post.
I will watch you’ve shared with me and I’ll let you know if I solve my problem

Thanks

Hola Jesús !

I woud try to create a measure for Activity Days from the Fact table (Ordenes de servicio). This is the measure I think you need:
Days of activity = calculate (COUNTROWS(DISTINCT(‘Ordenes de Servicio Interna’[Date])))

Finally to create the average I would divide the ‘Total’ (You would need to create a new measure) by the ‘Days of activity’

Hope it helps !

Juanjo

Hi @Jesus74, we’ve noticed that no response has been received from you since the 9th of April. We just want to check if you still need further help with this post? In case there won’t be any activity on it in the next few days, we’ll be tagging this post as Solved. If you have a follow question or concern related to this topic, please remove the Solution tag first by clicking the three dots beside Reply and then untick the checkbox. Thanks!