Forum Discussion

Marco Albanese's avatar
Marco Albanese
Copper Contributor
Oct 04, 2017
Solved

Excel subtraction

Hi all, I'm writing because I would like to know if there is a fast way to do the following thing using excel. Let's say I have 10 rows (from 2 to 11) and one column(B) filled with numerical data.....
  • SergeiBaklan's avatar
    SergeiBaklan
    Oct 04, 2017

    Hi Marco,

     

    In general that's combination of absolute and relative references like formula

    =$B$2-$B3

    copied down till end of you range.

    How to modify the formula depends on where and how you'd like to show result. For example, to fill this matrix

    where in first row is the index from which we start substruction the formula in C2 could be

    =IF(ROW()<=C$1,0,OFFSET($B$2,C$1-2,0)-$B2)

    which we copy into all other cells. OFFSET says from which number we substruct in particular column.

    Please see attached file

     

Resources