jduran04
asked on
Simplify an Excel Formula
Does anyone know how to simplify this Excel formula: b12+b19+b27+b34+b42+b49+b5 6+b64+b71+ b78+b86+b9 3?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Those cells are not equi-distant. Is that correct? If so, they are not consistently differently spaced either. Is that also correct? If so, the only way to simplify is to name those cells together as a range, then use formula like =SUM(MyNamedRange)
if they should be equidistant, then a formula like: =SUMPRODUCT((MOD(ROW(B12:B 93)-ROW(B1 2),7)=0)+0,B12:B93)
where the cells are 7 apart.
if they should be equidistant, then a formula like: =SUMPRODUCT((MOD(ROW(B12:B
where the cells are 7 apart.
Other option that this could cover.
If for example your formulas in the source cells are a sum of above eg:
B12 contains =SUM(B1:B11)
B19 contains =SUM(B13:B18) etc
Then in B94 you have the above multiple sums summated, you could change to a SUBTOTAL.
In each of the source SUMS change to SUBTOTAL
B12 contain =SUBTOTAL(9,B1:B11)
B19 contain =SUBTOTAL(9,B13:B18)
Then in B94
=SUBTOTAL(9,B1:B93)
This last SUBTOTAL will ignore other subtotals within the range.
Rather than manually replacing each of the SUMs with SUBTOTALs use the Edit - Replace function (Ctrl + h)
Find SUM(
Replace with SUBTOTAL(9,
Thanks
Rob H
If for example your formulas in the source cells are a sum of above eg:
B12 contains =SUM(B1:B11)
B19 contains =SUM(B13:B18) etc
Then in B94 you have the above multiple sums summated, you could change to a SUBTOTAL.
In each of the source SUMS change to SUBTOTAL
B12 contain =SUBTOTAL(9,B1:B11)
B19 contain =SUBTOTAL(9,B13:B18)
Then in B94
=SUBTOTAL(9,B1:B93)
This last SUBTOTAL will ignore other subtotals within the range.
Rather than manually replacing each of the SUMs with SUBTOTALs use the Edit - Replace function (Ctrl + h)
Find SUM(
Replace with SUBTOTAL(9,
Thanks
Rob H
If your cells move a lot, you could use names on them to ensure that you can see that they're correctly defined. It would make the formula longer, but easier to understand or bug-check.
eg
=SalesJan+SalesFeb+SalesMa r
To define the names quickly, select the cell you wish to name, and then type the name in the box to the LEFT of the formula bar (it will currently display the cell ref).
Then, whenever you build a formula that needs that cell, click it, and the formula will use the name, rather than the cell ref.
eg
=SalesJan+SalesFeb+SalesMa
To define the names quickly, select the cell you wish to name, and then type the name in the box to the LEFT of the formula bar (it will currently display the cell ref).
Then, whenever you build a formula that needs that cell, click it, and the formula will use the name, rather than the cell ref.
But you may place it into some unused cell (e.g. az1) and then use just the reference to az1 (multiple times).