Complete the following steps to stack data from a set of rows into a column.
- In Rows to be stacked are in the following columns, enter the columns that contain the data that you want to put into a single column.
- In Store stacked data in, enter a column number (for example, C6) or a column name in which to store the stacked data. If the column name has more than one word, enclose the name in single quotation marks.
- To store row subscripts, select Store row subscripts in, then enter a column number (for example, C7) or a column name. If the column name has more than one word, enclose the name in single quotation marks.
- To store column subscripts, select Store column subscripts in, then enter a column number (for example, C8) or a column name. If the column name has more than one word, enclose the name in single quotation marks.
- To include corresponding values from other columns with the stacked rows, select Expand the following columns while stacking rows, then enter the columns to expand.
- If you are expanding columns, in Store the expanded columns in, enter a column number (for example, C9) or name for each column that you are expanding. If the column name has more than one word, enclose the name in single quotation marks.
For example, in following worksheet, the data in the Seattle, Boston, and New York columns are stacked into the Sales column. The Qtr column contains the row subscripts and the City column contains the column subscripts. The column Advertising is expanded into the column Adv.
C1 |
C2 |
C3 |
C4 |
C5 |
C6 |
C7 |
C8-T |
C9 |
Quarter |
Seattle |
Boston |
New York |
Advertising |
Sales |
Qtr |
City |
Adv |
1 |
63 |
36 |
52 |
63 |
63 |
1 |
Seattle |
63 |
2 |
71 |
32 |
46 |
75 |
36 |
1 |
Boston |
63 |
3 |
68 |
35 |
51 |
68 |
52 |
1 |
New York |
63 |
4 |
66 |
29 |
50 |
79 |
71 |
2 |
Seattle |
75 |
|
|
|
|
|
32 |
2 |
Boston |
75 |
|
|
|
|
|
46 |
2 |
New York |
75 |
|
|
|
|
|
68 |
3 |
Seattle |
68 |
|
|
|
|
|
35 |
3 |
Boston |
68 |
|
|
|
|
|
51 |
3 |
New York |
68 |
|
|
|
|
|
66 |
4 |
Seattle |
79 |
|
|
|
|
|
29 |
4 |
Boston |
79 |
|
|
|
|
|
50 |
4 |
New York |
79 |