Forum Discussion
Forecasting current month based on data so far
- 9 years ago
Hi
I modified your sample data a bit as follows:
I created a measure called "ForecastMonthly" that calculates the forecast (you might have to replace the semicolons with commas):ForecastMonthly =
CALCULATE(
DIVIDE(
SUM(Revenue[Revenue]);
DAY(MAX(Revenue[Date])) /*Last day with sales*/
)
* Day(EOMONTH(MAX(Revenue[Date]);0)); /*Days in Month*/
FILTER(Revenue;EOMONTH(Revenue[Date];0)=EOMONTH(TODAY();0) /*Calculate the forecast only for the current month*/
))
+
CALCULATE(SUM(Revenue[Revenue]);
FILTER(Revenue;EOMONTH(Revenue[Date];0) < EOMONTH(TODAY();0))) /*Calculate the revenue for the past months*/Explanation:
The first part calculates the forecast for the current month by summing up the revenues. Then dividing the summed up revenues by the number of days for the last sale and then multiplying it with the total days of the month.
The second part simply sums up the revenues for all past months.
The result:
Hope this helpsJJ
Hi
I modified your sample data a bit as follows:
I created a measure called "ForecastMonthly" that calculates the forecast (you might have to replace the semicolons with commas):
ForecastMonthly =
CALCULATE(
DIVIDE(
SUM(Revenue[Revenue]);
DAY(MAX(Revenue[Date])) /*Last day with sales*/
)
* Day(EOMONTH(MAX(Revenue[Date]);0)); /*Days in Month*/
FILTER(Revenue;EOMONTH(Revenue[Date];0)=EOMONTH(TODAY();0) /*Calculate the forecast only for the current month*/
))
+
CALCULATE(SUM(Revenue[Revenue]);
FILTER(Revenue;EOMONTH(Revenue[Date];0) < EOMONTH(TODAY();0))) /*Calculate the revenue for the past months*/
Explanation:
The first part calculates the forecast for the current month by summing up the revenues. Then dividing the summed up revenues by the number of days for the last sale and then multiplying it with the total days of the month.
The second part simply sums up the revenues for all past months.
The result:
Hope this helps
JJ
This was very helpful, how would I go about forcasting out the rest of the year? I've tried so many things and I can't seem to get it to work. TIA