We have a dashboard that pulls magento sales into a leaderboard that shows sales for the previous day, current week, quarterly, monthly and yearly. One of the features is a section called PACING. This section shows, based on previous sales, what they are on pace to sell for the week, month, quarter, and year. Here is the issue:
The week runs Monday through Sunday. Sales are very high Monday through Friday but drop substantially on Saturday and Sunday. Sales are about 25% of the volume on saturdays and sundays compared to mon through friday. So if we have sales of $20k total on Mon - Tues, a simple equation of ($20k / 2) x 7 will not work. The pacing will be too high because Saturday and Sunday will have the mentioned decline. My next solution was taking 76% of daily sales. But this formula fails as well:
((total sales / # of days sold) x .768) x 7
that works earlier in the week, but as the week gets later, the formula fails because pacing actually falls BEHIND the total sales. In that scenario, imagine we have sold $60k through Saturday:
((60,000 / 6) x .768) x 7 = 53,760
See above? the pace is actually LOWER than the actual sales total.
The easiest way to do this would be simply take the daily average of the week and anticipate Saturday and Sunday will be 25% of the average. But the current coder has not made formulas set up to recognize the difference between monday - friday and sat / sun. He just uses one generic day in formula.
I am looking for someone that can help us creating pacing formulas that will recognize in our admin when we set a date range, how many days are mon - friday week days and how many weekends sat / sun are in the date range and build a formula like:
(take total sold / total amount of days sold) x total amount of days in period but then be able to know how many WEEKENDS are in the future of time range and count those with anticipated 25% of daily average sold.
see screenshot of calendar / date scraper we use.