18.11.2014 Views

Microsoft Office

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Introducing Array Formulas<br />

One of Excel’s most interesting (and most powerful) features is its ability to<br />

work with arrays in formulas. When you understand this concept, you’ll<br />

be able to create elegant formulas that appear to perform spreadsheet<br />

magic.<br />

This chapter introduces the concept of arrays and is required reading for anyone<br />

who wants to become a master of Excel formulas. Chapter 18 continues with lots<br />

of useful examples.<br />

Understanding Array Formulas<br />

If you do any computer programming, you’ve probably been exposed to the concept<br />

of an array. An array is simply a collection of items operated on collectively<br />

or individually. In Excel, an array can be one dimensional or two dimensional.<br />

These dimensions correspond to rows and columns. For example, a onedimensional<br />

array can be stored in a range that consists of one row (a horizontal<br />

array) or one column (a vertical array). A two-dimensional array can be stored in a<br />

rectangular range of cells. Excel doesn’t support three-dimensional arrays (but its<br />

VBA programming language does).<br />

As you’ll see, arrays need not be stored in cells. You can also work with arrays<br />

that exist only in Excel’s memory. You can then use an array formula to manipulate<br />

this information and return a result. An array formula can occupy multiple<br />

cells or reside in a single cell.<br />

This section presents two array formula examples: an array formula that occupies<br />

multiple cells and another array formula that occupies only one cell.<br />

IN THIS CHAPTER<br />

The definition of an array and an<br />

array formula<br />

One-dimensional versus twodimensional<br />

arrays<br />

How to work with array<br />

constants<br />

Techniques for working with<br />

array formulas<br />

Examples of multicell array<br />

formulas<br />

Examples of array formulas that<br />

occupy a single cell<br />

313

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!