excel learner

asked on

# Understanding offset function

Dear experts,

I have the below formulae,

=IF(COUNT(MATCH(C4,'data elements'!B3:K3,0)*MATCH(E3,'data elements'!A4:A9,0)),INDEX(data elements'!A2:A22,04,'data elements'!B3:K3,0)),0)

What i want to understand is how does the function 'offset' and ')-1' work, what is the logic of this.

'INDEX(OFFSET('data elements'!B4:K9,MATCH(B2,'data elements'!A2:A22,0)-1,0),'

Thank you

I have the below formulae,

=IF(COUNT(MATCH(C4,'data elements'!B3:K3,0)*MATCH(E

**OFFSET**('data elements'!B4:K9,MATCH(B2,'

**)-1,0),**MATCH(E3,'data elements'!A4:A9,0),MATCH(C

What i want to understand is how does the function 'offset' and ')-1' work, what is the logic of this.

'INDEX(OFFSET('data elements'!B4:K9,MATCH(B2,'

Thank you

so to your question -1 is the height relatively the range parameter.

so if range is C4, -1 as height parameter yields C3

so if range is C4, -1 as height parameter yields C3

ASKER CERTIFIED SOLUTION

membership

This solution is only available to members.

To access this solution, you must be a member of Experts Exchange.

ASKER

Barry, superb as usual

Offset( range, rows, columns, height, width )

range is the starting range from which the offset will be applied.

rows is the number of rows to apply as the offset to the range. This can be a positive or negative number.

columns is the number of columns to apply as the offset to the range. This can be a positive or negative number.

height is the number of rows that you want the returned range to be.

width is the number of columns that you want the returned range to be.

http://www.techonthenet.com/excel/formulas/offset.php