Summarize array data

tana

New Member
Joined
Jan 22, 2021
Messages
49
Office Version
  1. 365
Platform
  1. Windows
Hi,

Can I have help on a situation which involves with array data?

I have the following categories to summarize (some may have cost data, some may not):

C20288 High Voltage Switch Replacements 202411.xlsx
X
3Project Management & Administrative
4Internal Engineering
5External Engineering
6Construction Labour
7Construction Equipment
8Construction Services
9Materials
10Contingency
11Allowance
Input


Then I have these cost data in an array:
C20288 High Voltage Switch Replacements 202411.xlsx
XY
16Project Management & Administrative500
17Internal Engineering500
18External Engineering33000
19Project Management & Administrative1750
20Internal Engineering1750
21External Engineering58000
22Construction Labour1100
23Construction Equipment200
24Construction Services0
25Materials142000
26Project Management & Administrative600
27Internal Engineering500
28External Engineering28000
29Project Management & Administrative500
30Internal Engineering500
31External Engineering0
32Project Management & Administrative520
33Internal Engineering500
34External Engineering19731.51
35Project Management & Administrative700
36Internal Engineering500
37External Engineering19326.79
38Project Management & Administrative680
39Internal Engineering500
40External Engineering22285.26
41Project Management & Administrative630
42Internal Engineering500
Input
Cell Formulas
RangeFormula
X16:Y42X16=CHOOSECOLS(R3#,2,3)
Dynamic array formulas.


I would like to have spilled formula which can summarize by category. Thanks!
 

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
How about
Fluff.xlsm
XY
1
2
3Project Management & Administrative5880
4Internal Engineering5250
5External Engineering180343.6
6Construction Labour1100
7Construction Equipment200
8Construction Services0
9Materials142000
10Contingency0
11Allowance0
12
13
14
15
16Project Management & Administrative500
17Internal Engineering500
18External Engineering33000
19Project Management & Administrative1750
20Internal Engineering1750
21External Engineering58000
22Construction Labour1100
23Construction Equipment200
24Construction Services0
25Materials142000
26Project Management & Administrative600
27Internal Engineering500
28External Engineering28000
29Project Management & Administrative500
30Internal Engineering500
31External Engineering0
32Project Management & Administrative520
33Internal Engineering500
34External Engineering19731.51
35Project Management & Administrative700
36Internal Engineering500
37External Engineering19326.79
38Project Management & Administrative680
39Internal Engineering500
40External Engineering22285.26
41Project Management & Administrative630
42Internal Engineering500
43
Sheet6
Cell Formulas
RangeFormula
Y3:Y11Y3=SUMIFS(Y16:Y10000,X16:X10000,X3:X11)
Dynamic array formulas.
 
Upvote 0
How about
Fluff.xlsm
XY
1
2
3Project Management & Administrative5880
4Internal Engineering5250
5External Engineering180343.6
6Construction Labour1100
7Construction Equipment200
8Construction Services0
9Materials142000
10Contingency0
11Allowance0
12
13
14
15
16Project Management & Administrative500
17Internal Engineering500
18External Engineering33000
19Project Management & Administrative1750
20Internal Engineering1750
21External Engineering58000
22Construction Labour1100
23Construction Equipment200
24Construction Services0
25Materials142000
26Project Management & Administrative600
27Internal Engineering500
28External Engineering28000
29Project Management & Administrative500
30Internal Engineering500
31External Engineering0
32Project Management & Administrative520
33Internal Engineering500
34External Engineering19731.51
35Project Management & Administrative700
36Internal Engineering500
37External Engineering19326.79
38Project Management & Administrative680
39Internal Engineering500
40External Engineering22285.26
41Project Management & Administrative630
42Internal Engineering500
43
Sheet6
Cell Formulas
RangeFormula
Y3:Y11Y3=SUMIFS(Y16:Y10000,X16:X10000,X3:X11)
Dynamic array formulas.
I tried and keep coming up with an error message.

The formula I inserted was =SUMIFS(CHOOSECOLS(X16#,2),CHOOSECOLS(X16#,1),X3)

The error message is
There's a problem with this formula.
Not trying to type a formula?
When the first character is an equal("=") or minus ("-") sign, Excel think it's a formula...........

By the way, let me provide the full data which is an array, this is what I have
C20288 High Voltage Switch Replacements 202411.xlsx
RSTU
321656352Project Management & Administrative500500
421656352Internal Engineering500500
521656352External Engineering330000
621656348Project Management & Administrative17501000
721656348Internal Engineering17501000
821656348External Engineering580000
921656348Construction Labour1100157171
1021656348Construction Equipment2001000
1121656348Construction Services01000
1221656348Materials1420000
1321656358Project Management & Administrative6000
1421656358Internal Engineering5000
1521656358External Engineering280000
1621704689Project Management & Administrative500500
1721704689Internal Engineering500500
1821704689External Engineering014136.24
1921704691Project Management & Administrative520500
2021704691Internal Engineering500500
2121704691External Engineering19731.5119731.51
2221704693Project Management & Administrative700500
2321704693Internal Engineering500500
2421704693External Engineering19326.7919326.79
2521704695Project Management & Administrative680500
2621704695Internal Engineering500500
2721704695External Engineering22285.2622285.26
2821704697Project Management & Administrative630500
2921704697Internal Engineering500500
Input
Cell Formulas
RangeFormula
R3:U29R3=LET( all,FILTER('Bottom-up Financial AUC'!A2:S202,TAKE('Bottom-up Financial AUC'!A2:S202,,1)<>0), x,COUNTIF(L40:L47,DROP(TAKE(all,,2),,1)), a,FILTER(HSTACK(x,all),x<>0), b,FILTER(a,TAKE(DROP(a,,-1),,-1)<>0), f,DROP(DROP(b,,-3),,1), ff,TAKE(f,,2), n,Input!M3, fe,TAKE(f,,-(12-n+1)), HSTACK(ff,fe))
Dynamic array formulas.


There are few more cols which is the monthly cost by different months.
I would like to summarize it by category with spilled formula if possible. Thanks,
 
Last edited:
Upvote 0
Did you try the formula I suggested?
 
Upvote 0
Did you try the formula I suggested?
Yes, I think, since my data is an array, I have adjusted your formula to fit the situation, but same concept without hard coded cells.

The one I demonstrate earlier is my trial using sumifs.
By the way, I can't use groupby or pivotby yet. Thanks,
 
Upvote 0
What is wrong with the formula I posted?
 
Upvote 0
What is wrong with the formula I posted?
oh, nothing is wrong. I just adjusted to fit my sitation with array in there. =SUMIFS(CHOOSECOLS(X16#,2),CHOOSECOLS(X16#,1),X3)
 
Upvote 0
You cannot use an array in sumifs like that.
If there is nothing wrong the formula I posted, why don't you use it?
 
Upvote 0
You cannot use an array in sumifs like that.
If there is nothing wrong the formula I posted, why don't you use it?
:) I prefer to use array so I don't need to drag the formula every update and it will be automatically.
 
Upvote 0
You don't need to drag the formula, it's a spill range. Just change the value of the last row well below your expected data.
 
Upvote 0

Forum statistics

Threads
1,226,112
Messages
6,189,039
Members
453,521
Latest member
Chris_Hed

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