Chapter 3. INDEX function

Questions answered in this chapter:

  • I have a list of distances between US cities. How can I write a function that returns the distance between, for example, Seattle and Miami?

  • Can I write a formula that references the entire column containing the distances between each city and Seattle?

Syntax of the INDEX function

The INDEX function enables you to return the entry in any row and column within an array of numbers. The most commonly used syntax for the INDEX function is the following:

INDEX(Array,Row Number,Column Number)

To illustrate, the INDEX(A1:D12,2,3) formula returns the entry in the second row and third column of the A1:D12 array. This entry is the one in cell C2.

Answers to this chapter’s questions

This section provides ...

Get Microsoft Excel 2013: Data Analysis and Business Modeling now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.