What’s the Numbers equivalent to Excel’s “A1:A10-B1”

numbers

I'm switching from Microsoft Excel to Number.app, in Excel you can do

=SUMPRODUCT((A1:A5-A1)^2,B1:B5)

the a1:a10-b1 bit will return a cell range equivalent to a1:a10 but with all the cells decremented by b1. What's the proper syntax in Numbers for that?

If I try to import an Excel workbook using that syntax into Numbers, that formula will be imported verbatim and Numbers will complain.

Best Answer

In numbers, SUMPRODUCT (range, range…) takes the following arguments:

range: A range of cells. range is a reference to a single range of cells containing values of any type. If string or Boolean values are included in range, they are ignored.

range…: Optionally include one or more additional ranges of cells. The ranges must all have the same dimensions.

So you'll need to set up a range to perform the initial calculation (and squaring) and then sumproduct two simple ranges.