+ Reply to Thread
Results 1 to 5 of 5

Dynamic cumulative sum formula (?!)

  1. #1
    Registered User
    Join Date
    05-13-2016
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    3

    Dynamic cumulative sum formula (?!)

    Hi, new to the forum, hope someone can help....

    I attach a simplified version the spreadsheet I am working on so as to isolate the particular issue as best I can.

    It shows sales projects in terms of units of product on a month by month basis over a 12 month period.

    Below each month's entry are 2 further entries 'Min Reorder period ending Month' and 'Min Reorder Quantity'. Values for eacvh entry have been entered manually for the sake of this post. I am looking for a way to get excel to calculate this values - ideally without having to enter more data to help it get there.


    Min Reorder period ending Month: refers to the FUTURE Month in which - if I order product in the current month (the month the 'Min Reorder period ending Month' text sits under - I will have made projected sales that reach the supplier's min order quantity. For this example this quantity is 100.


    Min Reorder Quantity
    - refers to the actual quantity - based on projected sales - of product I would need to order when making this order.

    Clearly these 2 figures change with each month.

    The figures manually filled in illustrate how: eg in Month 1 I will need to order 112 units (the sum of b2:n2 being the first cumulate sum in that row to be equal to or more than 100); it also tells me that I will have ordered enough to cover my projected sales until Mom=nth 7 if I order this amount in the current month - in this example Month 1.

    Is there a way of getting a formula to make these calculations?

    I realise that if I had a tally of the cumulative projected orders month by month that I could use MIN(IF which I have done in cell B10 using cumulative data in Row 3.

    BUT the problem with that is that I have to have a different row of cumulative data for each new month so that the formula would be sure to look up the correct cumulative order amount relative to IT. This is illustrated by the entry in D10 - using the same Min(if formula for month 2 it simply returns the same result as for Month 1, which is clearly not correct.

    I'd really prefer not to have many rows of different cumulative projected sales data to make this work. Can anyone help? Hope this is clear!
    Attached Files Attached Files

  2. #2
    Forum Expert rorya's Avatar
    Join Date
    08-13-2008
    Location
    East Sussex, UK
    MS-Off Ver
    365 Ent Monthly Channel / Insiders Beta
    Posts
    8,903

    Re: Dynamic cumulative sum formula (?!)

    Just to clarify, is this the actual layout of your data? In other words, do you currently have two columns per month, and the cumulative data in row 3 anyway?

  3. #3
    Registered User
    Join Date
    05-13-2016
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Dynamic cumulative sum formula (?!)

    Hi Rorya, thanks for the response!

    Actual worksheet is quite a bit more complex and is still a work in progress. But essentially, as it stands,:

    yes, I have 2 columns per month
    no, the cumulative data is in the same column (one row above the incremental data).

    BUT I am very happy to change the layout - as I said, this is a work in progress, all is flexible.

    Does this help?

  4. #4
    Forum Expert
    Join Date
    06-08-2012
    Location
    Left the forum!
    MS-Off Ver
    Left the forum!
    Posts
    5,189

    Re: Dynamic cumulative sum formula (?!)

    This array formula will find the column where the cumulative sum in row 2 is >= 100

    =MATCH(TRUE,SUBTOTAL(9,OFFSET($B$2,0,0,1,COLUMN($B$2:$X$2)-COLUMN($B$2)+1))>=100,0)

    For the purpose of testing, I had the above formula in B12, reflected in the formula below, they can be nested as required.

    This will return the month

    =INDEX($B$1:$Y$1,B12+1)

    and this, the re-order quantity.

    =SUM($B$2:INDEX($B$2:$X$2,B12))

    edit:-

    Formulas above are based on your sample, I've changed the layout of your sheet and tweaked some of the references in the formulas, will this work for you? (see attached file).
    Attached Files Attached Files
    Last edited by jason.b75; 05-13-2016 at 07:41 AM.

  5. #5
    Registered User
    Join Date
    05-13-2016
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Dynamic cumulative sum formula (?!)

    Jason - fantastic, nailed it. Very grateful INDEED!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Calculate cumulative depreciation over time with a dynamic column range
    By jeremylittman in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 06-07-2015, 09:50 PM
  2. [SOLVED] Cumulative Sum Formula
    By Leaps222 in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 09-28-2014, 11:04 AM
  3. [SOLVED] Dynamic cumulative SUM RANGE - different months
    By epsiloni in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 12-15-2013, 11:36 AM
  4. Replies: 8
    Last Post: 12-06-2013, 01:42 PM
  5. [SOLVED] Seeking formula for cumulative sum
    By Vagulus in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 07-16-2013, 06:54 PM
  6. Cumulative sum formula
    By Africa in forum Excel General
    Replies: 9
    Last Post: 02-08-2012, 05:42 AM
  7. cumulative interest formula
    By Farnarkler in forum Excel General
    Replies: 3
    Last Post: 11-18-2008, 09:48 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1