+ Reply to Thread
Results 1 to 4 of 4

How to Speed Up Large Matrix Array Formulas

  1. #1
    Registered User
    Join Date
    12-31-2013
    Location
    Columbus, OH
    MS-Off Ver
    Excel 2007
    Posts
    2

    How to Speed Up Large Matrix Array Formulas

    Hello all, first time poster here, so please go easy on me...

    Background: I am trying to calculate a matrix of array formulas that is roughly 365 x 137, or about 50,000 cells being calculated from a range of roughly 12,000 x 137. There are multiple if statements within the array formula, and then those 50,000 cells are referenced to another, but smaller matrix of array formulas (25 x 137). Each of these matrix sets is for one year, and there are three years that need calculated.

    Problem: When calculating the 50,000 cells it takes roughly 2.5 hours to complete all calculations. So, for 3 years it will take roughly one work day of tying up my computer to just compile data that will then require several days of calculation/manipulation.

    Question(s): Is there a way to speed this up to a reasonable amount of time (I'd even take 30 minutes at this point)? Or, is Excel simply the wrong tool to be using for this amount of data? Do I need a better machine to run these calculations? I am currently using a Dell XT3 with 2.5 Ghz i5 quad core processor.

    Thanks in advance and please let me know if there is anything else that might help in answering these questions.

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,455

    Re: How to Speed Up Large Matrix Array Formulas

    Hi
    without seeing some of your data and formula, it's difficult to say.
    Could you post a sample sheet on the forum ?

  3. #3
    Registered User
    Join Date
    12-31-2013
    Location
    Columbus, OH
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: How to Speed Up Large Matrix Array Formulas

    Here is the formula that is from the 365 x 137 matrix:

    MAX(IF(B$3=STORE_LIST_2013,IF($A4=CALENDAR_DATE_2013,HHOUR_TRANS_DATA_2013,""),))

    B3 is store name, and A4 is the date.

    Range "STORE_LIST_2013" is 137 cells, and range "CALENDAR_DATE_2013" is about 12,000 cells.

  4. #4
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP and 2007
    Posts
    15,877

    Re: How to Speed Up Large Matrix Array Formulas

    Whenever I see these kind of questions, I am reminded of this discussion between benishiryo and I http://www.excelforum.com/excel-form...ml#post3111341 What I observed in his examples is that there is a significant duplication of effort for each incidence of the desired function. It looks like that will be the case in your example here, too. Each incidence of that function will need to evaluate both the A4=calendar data 2013 array and the b3=storelist2013 array. And, when you have 20000 incidences of the function, that is a significant duplication of effort.

    I know it is not a popular suggestion (for some reason, even with 1E6 rows and 1E4 columns, we want to use as few cells as possible), but my suggestion would be to use helper columns or blocks of helper cells to reduce this duplication of effort. Build a separate matrix as a subset of the raw data matrix that will show store B3 for calendar date A4 or some other way to shrink extract the desired data before calculating the max.
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

+ 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. Array looping, increase speed of array macro
    By techrcn in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 11-27-2013, 05:33 AM
  2. Array formulas for a large dataset
    By Freedan in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-25-2012, 12:48 PM
  3. Speed of copying in large spreadsheets
    By mpalmi1037 in forum Excel General
    Replies: 0
    Last Post: 03-31-2009, 05:45 PM
  4. Large .csv file VBA speed
    By vwgolfman in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 08-17-2007, 01:25 PM
  5. [SOLVED] Problem with speed of PasteSpecial for large ranges
    By xlb in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-20-2005, 09:06 AM

Tags for this Thread

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