Overview for Stack Columns

Use Stack Columns to copy data from two or more columns to one longer column. When you stack columns, Minitab also creates a column of IDs to indicate which group each observation belongs to. You can use this ID column as a group variable in analyses and graphs.

For example, a sales manager wants to analyze sales data for four cities. The manager needs to have all the sales in one column and the city in another column.

In this worksheet, columns C1–C3 contain the unstacked sales data. Columns C4–C5 contain the stacked data. The Sales column contains the sales values and the ID column, City, indicates which city each sales value is from.
C1 C2 C3 C4 C5
Seattle Boston New York City Sales
63 36 52 Seattle 63
71 32 46 Seattle 71
68 35 51 Seattle 68
66 29 50 Seattle 66
      Boston 36
      Boston 32
      Boston 35
      Boston 29
      New York 52
      New York 46
      New York 51
      New York 50

Where to find this command

  • Mac: Data > Stack Columns
  • PC: DATA > Stack Columns
By using this site you agree to the use of cookies for analytics and personalized content.  Read our policy