Sliding Summary of Values

GoHeels

New Member
Joined
May 14, 2008
Messages
27
Preference this with many thanks for recommendations to resolve my issue.

From a high level, I have a worksheet with forecasted values by retail location for 500+ stores for 12/1/2021-12/31/2021. Each store has an average number of pickup days that varies across each location. What I would like to do is forecast out the potential moving carryover by day for each store, to determine the max capacity/carryover during the period.

For example, Location A has an average pickup day value of 2, we should see on dates:
12/1/2021 = 12/1/2021
12/2/2021 = 12/1/2021+12/2/2021
12/3/2021 = 12/2/2021+12/3/2021 -------Values from 12/1 are dropped since that is outside of the average pickup window of 2 days
12/4/2021 = 12/3/2021+12/4/2021--------Values from 12/2 are dropped
12/5/2021 = 12/4/2021+12/5/2021--------Values from 12/3 are dropped


Location B has an average pickup day value of 5, so we should see on dates:
12/1/2021 = 12/1/2021
12/2/2021 = 12/1/2021+12/2/2021
12/3/2021 = 12/1/2021+12/2/2021+12/3/2021
12/4/2021 = 12/1/2021+12/2/2021+12/3/2021+12/4/2021
12/5/2021 = 12/1/2021+12/2/2021+12/3/2021+12/4/2021+12/5/2021
12/6/2021 = 12/2/2021+12/3/2021+12/4/2021+12/5/2021+12/6/2021-------Values from 12/1 are dropped since that is outside of the average pickup window of 5 days

Printscreen below with some basic examples.
Screen Shot 2021-11-03 at 11.49.29 AM.png


The values that happen prior to 12/1 are not considered here, only 12/1 and forward, so we only want to keep the forecasted moving values from 12/1-12/31. Any help here would be greatly appreciated. Thanks in advance.
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.
Try:

Book2
ABCDEFGHIJKLMNOPQRSTU
1LocationAvg Pickup Days12/1/202112/2/202112/3/202112/4/202112/5/202112/6/202112/7/202112/8/202112/9/202112/1/202112/2/202112/3/202112/4/202112/5/202112/6/202112/7/202112/8/202112/9/2021
2A2100150200250300200100100100100250350450550500300200200
3B5100150200250300200100100100100250450700100011001050950800
4C1100150200250300200100100100100150200250300200100100100
Sheet8
Cell Formulas
RangeFormula
M2:U4M2=SUM(INDEX(2:2,MAX(3,MATCH(M$1,$A$1:$K$1,0)-$B2+1)):INDEX(2:2,MATCH(M$1,$A$1:$K$1,0)))
 
Upvote 0
Solution

Forum statistics

Threads
1,214,653
Messages
6,120,752
Members
448,989
Latest member
mariah3

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top