---
title: "Column"
language: "en"
type: "Symbol"
summary: "Column[{expr1, expr2, ...}] is an object that formats with the expri arranged in a column, with expr1 above expr2, etc. Column[list, alignment] aligns each element horizontally in the specified way. Column[list, alignment, spacing] leaves the specified number of x-heights of spacing between successive elements."
keywords: 
- column of objects
- column alignment
- stacking of objects
- vertical stacking
- vertical collection
- stacked output
- vertical output
- BoxColumn
- Table
- Vector
- vertcat
canonical_url: "https://reference.wolfram.com/language/ref/Column.html"
source: "Wolfram Language Documentation"
related_guides: 
  - 
    title: "Grids & Tables"
    link: "https://reference.wolfram.com/language/guide/GridsAndTables.en.md"
  - 
    title: "Layout & Tables"
    link: "https://reference.wolfram.com/language/guide/LayoutAndTables.en.md"
  - 
    title: "Computation with Structured Datasets"
    link: "https://reference.wolfram.com/language/guide/ComputationWithStructuredDatasets.en.md"
  - 
    title: "Palettes"
    link: "https://reference.wolfram.com/language/guide/Palettes.en.md"
  - 
    title: "Notebook Formatting & Styling"
    link: "https://reference.wolfram.com/language/guide/NotebookFormattingAndStyling.en.md"
  - 
    title: "Mathematical Typesetting"
    link: "https://reference.wolfram.com/language/guide/MathematicalTypesetting.en.md"
  - 
    title: "User Interface Structuring & Layout"
    link: "https://reference.wolfram.com/language/guide/UserInterfaceStructuringAndLayout.en.md"
  - 
    title: "Data Visualization"
    link: "https://reference.wolfram.com/language/guide/DataVisualization.en.md"
  - 
    title: "Automated Reports"
    link: "https://reference.wolfram.com/language/guide/AutomatedReports.en.md"
  - 
    title: "Basic Input & Output in Programs"
    link: "https://reference.wolfram.com/language/guide/BasicInputAndOutputInPrograms.en.md"
related_workflows: 
  - 
    title: "Make a Grid of Output Data"
    link: "https://reference.wolfram.com/language/workflow/MakeAGridOfOutputData.en.md"
  - 
    title: "Create a Palette"
    link: "https://reference.wolfram.com/language/workflow/CreateAPalette.en.md"
related_functions: 
  - 
    title: "GraphicsColumn"
    link: "https://reference.wolfram.com/language/ref/GraphicsColumn.en.md"
  - 
    title: "Row"
    link: "https://reference.wolfram.com/language/ref/Row.en.md"
  - 
    title: "Multicolumn"
    link: "https://reference.wolfram.com/language/ref/Multicolumn.en.md"
  - 
    title: "Grid"
    link: "https://reference.wolfram.com/language/ref/Grid.en.md"
  - 
    title: "Labeled"
    link: "https://reference.wolfram.com/language/ref/Labeled.en.md"
  - 
    title: "InsertLinebreaks"
    link: "https://reference.wolfram.com/language/ref/InsertLinebreaks.en.md"
related_tutorials: 
  - 
    title: "Tables and Matrices"
    link: "https://reference.wolfram.com/language/tutorial/TextualInputAndOutput.en.md#28366"
  - 
    title: "Grids, Rows, and Columns"
    link: "https://reference.wolfram.com/language/tutorial/GridsRowsAndColumnsOverview.en.md"
  - 
    title: "String‐Oriented Output Formats"
    link: "https://reference.wolfram.com/language/tutorial/TextualInputAndOutput.en.md#1899"
  - 
    title: "Formatted Output"
    link: "https://reference.wolfram.com/language/tutorial/TextualInputAndOutput.en.md#6589676"
---
# Column

Column[{expr1, expr2, …}] is an object that formats with the expri arranged in a column, with expr1 above expr2, etc. 

Column[list, alignment] aligns each element horizontally in the specified way. 

Column[list, alignment, spacing] leaves the specified number of x-heights of spacing between successive elements.

## Details and Options

* Possible alignments are:

|        |                                            |
| :----- | :----------------------------------------- |
| Center | centered                                   |
| Left   | left justified (default)                   |
| Right  | right justified                            |
| "c"    | align on the character "c"                 |
| {h, v} | separate horizontal and vertical alignment |

* ``Column[…]`` formats as a column in ``StandardForm``, ``TraditionalForm``, and ``OutputForm``.

* In ``InputForm``, ``Column[…]`` formats literally as ``Column[…]``.

* ``First[col]`` extracts the list that makes up a column.

* The ``expri`` can be expressions of any kind, including graphics and controls.

* You can enter text as an element of a ``Column`` by giving it as a string. You can use ``Text["string"]`` or ``Style["string", "style"]`` to specify a particular style.

* The following options can be given:

|                   |                  |                                                |
| :---------------- | :--------------- | :--------------------------------------------- |
| Alignment         | {Left, Baseline} | horizontal and vertical alignment of items     |
| Background        | None             | what background colors to use                  |
| BaselinePosition  | Automatic        | what to align with a surrounding text baseline |
| BaseStyle         | {}               | base style specifications for the column       |
| DefaultElement    | "∖[Placeholder]" | what element to insert in an empty item        |
| Dividers          | {}               | where to draw divider lines in the column      |
| Frame             | None             | where to draw frames in the column             |
| FrameStyle        | Automatic        | style to use for frames                        |
| ItemSize          | Automatic        | width and height of each item                  |
| ItemStyle         | None             | individual styles for items                    |
| Spacings          | Automatic        | horizontal and vertical spacings               |

* Common settings for ``Frame`` include:

|      |                                       |
| :--- | :------------------------------------ |
| None | no frame                              |
| True | frame around the whole column         |
| All  | frame around every item in the column |

* ``Column[list, alignment]`` is equivalent to ``Column[list, Alignment -> alignment]``.

* ``Column[list, alignment, spacing]`` corresponds to the setting ``Spacings -> spacing``.

* ``Background`` and ``ItemStyle`` can be lists giving settings for each item in the column.

* Settings for the options ``Alignment``, ``Background``, ``Frame``, ``ItemSize``, and ``ItemStyle`` can be given as follows to apply separately to successive items in the column:

|     |     |
| :------------------------------------- | :---------------------------------------------------------------------------------------------------------------------- |
| {s1, s2, …, sn} | use s1 through sn, then use defaults  |
| {{c}} | use c in all cases  |
| {{c1, c2}} | alternate between c1 and c2  |
| {{c1, c2, …}} | cycle through all ci |
| {s, {c}} | use s, then repeatedly use c  |
| {s1, {c}, sn} | use s1, then repeatedly use c, but use sn at the end  |
| {s1, s2, …, {c1, c2, … }, sm, … , sn}  | use the first sequence of si at the beginning, then cyclically use the ci, then use the last sequence of si at the end  |
| {s1, s2, …, {}, sm, …, sn} | use the first sequence of si at the beginning and the last sequence at the end |
| {i1 -> v1, i2 -> v2, …} | specify what to use at positions ik |
| {spec, rules} | use rules to override specifications in spec |

* With settings of the form ``{s1, s2, …, {…}, sm, …, sn}``, if there are more ``si`` specified than items in the column, ``si`` from the beginning are used for the first items, and ones from the end are used for the last items.

* Settings such as ``Alignment``, ``Background``, and ``Frame`` can effectively be specified for individual items in the column using ``Item``.

* With the default setting ``ItemSize -> Automatic``, ``Column`` will break elements across multiple lines if necessary.

* ``Column`` will not change the size of graphics or other objects that have explicit ``ImageSize`` settings.

* For a column of ``n`` elements, ``Dividers`` and ``Spacings`` can specify settings for the ``n + 1`` gaps between elements, starting before the first element and ending after the last element.

* Settings for ``Dividers`` and ``Spacings`` can have the following forms:

|                |                                                        |
| :------------- | :----------------------------------------------------- |
| spec           | apply spec to all gaps between items                   |
| {specx, specy} | apply speci to successive horizontal and vertical gaps |

* The ``speci`` can have the same forms as for ``Alignment``, ``Background``, and other item-oriented options.

* The following settings can be used for ``BaselinePosition`` :

|          |                                                 |
| :------- | :---------------------------------------------- |
| Axis     | axis of the middle row in the column (default)  |
| Baseline | baseline of the middle row in the column        |
| Bottom   | bottom of the whole column                      |
| Center   | halfway from top to bottom                      |
| Top      | top of the whole column                         |
| {i, pos} | position pos in element i                       |

* The settings for ``BaseStyle`` are appended to the default style typically given by the ``"Column"`` style in the current stylesheet.

---

## Examples (26)

### Basic Examples (2)

Display as a column:

```wl
In[1]:= Column[{1, 12, 123, 1234}]

Out[1]=
1
12
123
1234
```

---

Center each element:

```wl
In[1]:= Column[{1, 12, 123, 1234}, Center]

Out[1]=
1
12
123
1234
```

### Scope (4)

Add a frame around the column:

```wl
In[1]:= Column[{1, 22, 333, 4444}, Frame -> True]

Out[1]=
1
22
333
4444
```

---

Set the background:

```wl
In[1]:= Column[{1, 22, 333, 4444}, Background -> Pink]

Out[1]=
1
22
333
4444
```

---

Use alternating background colors:

```wl
In[1]:= Column[Table[n!, {n, 20, 25}], Background -> {{LightRed, Pink}}, Frame -> True]

Out[1]=
2432902008176640000
51090942171709440000
1124000727777607680000
25852016738884976640000
620448401733239439360000
15511210043330985984000000
```

---

Set the item size for line breaking:

```wl
In[1]:=
e = Expand[(x + y) ^ 10];
f = TrigExpand[Sin[9 x]];

In[2]:= Column[{e, f}, ItemSize -> {20, Automatic}, Frame -> All]

Out[2]=
x^10 + 10 x^9 y + 45 x^8 y^2 + 120 x^7 y^3 + 210 x^6 y^4 + 252 x^5 y^5 + 210 x^4 y^6 + 120 x^3 y^7 + 45 x^2 y^8 + 10 x y^9 + y^10
9 Cos[x]^8 Sin[x] - 84 Cos[x]^6 Sin[x]^3 + 126 Cos[x]^4 Sin[x]^5 - 36 Cos[x]^2 Sin[x]^7 + Sin[x]^9
```

### Options (19)

#### Alignment (1)

Align within the column:

```wl
In[1]:= Table[Column[{1, 22, 333}, Alignment -> a], {a, {Left, Center, Right}}]

Out[1]=
{1
22
333, 1
22
333, 1
22
333}
```

#### Background (1)

Change the overall background color:

```wl
In[1]:= Table[Column[{1, 22, 333}, Background -> c], {c, {LightRed, LightGreen, Pink}}]

Out[1]=
{1
22
333, 1
22
333, 1
22
333}
```

Change the background color of an individual row:

```wl
In[2]:= Column[{1, 22, 333}, Background -> {LightRed, LightGreen, Pink}]

Out[2]=
1
22
333
```

Alternate the background color:

```wl
In[3]:= Column[{1, 22, 333, 4444}, Background -> {{LightRed, Pink}}, Frame -> True]

Out[3]=
1
22
333
4444
```

#### BaselinePosition (1)

Align the column with surrounding text:

```wl
In[1]:= Row[Table[Column[{1, 22, 333}, BaselinePosition -> p, Frame -> True], {p, {Top, Center, Bottom}}], "xxx"]

Out[1]=
Row[{Column[{1, 22, 333}, BaselinePosition -> Top, Frame -> True], 
  Column[{1, 22, 333}, BaselinePosition -> Center, Frame -> True], 
  Column[{1, 22, 333}, BaselinePosition -> Bottom, Frame -> True]}, "xxx"]
```

#### Dividers (5)

Draw all dividers:

```wl
In[1]:= Column[{1, 22, 333}, Dividers -> All]

Out[1]=
1
22
333
```

---

Only draw exterior dividers:

```wl
In[1]:= Column[{1, 22, 333}, Dividers -> True]

Out[1]=
1
22
333
```

---

Draw only interior dividers:

```wl
In[1]:= Column[{1, 22, 333}, Dividers -> Center]

Out[1]=
1
22
333
```

---

Draw custom dividers:

```wl
In[1]:= Column[{1, 22}, Dividers -> {None, {1 -> Red, 2 -> Green, 3 -> Blue}}]

Out[1]=
1
22
```

Use negative-position indices:

```wl
In[2]:= Column[{1, 22}, Dividers -> {None, {-3 -> Red, -2 -> Green, -1 -> Blue}}]

Out[2]=
1
22
```

---

Draw outer column dividers:

```wl
In[1]:= Column[{1, 22}, Dividers -> {{1 -> Red, 2 -> Blue}, None}]

Out[1]=
1
22
```

Use negative-position indices:

```wl
In[2]:= Column[{1, 22}, Dividers -> {{-2 -> Red, -1 -> Blue}, None}]

Out[2]=
1
22
```

#### Frame (3)

Frame all elements:

```wl
In[1]:= Column[{1, 22, 333}, Frame -> All]

Out[1]=
1
22
333
```

---

Frame only the exterior:

```wl
In[1]:= Column[{1, 22, 333}, Frame -> True]

Out[1]=
1
22
333
```

---

Frame specific elements:

```wl
In[1]:= Column[{1, 22, 333}, Frame -> {None, True, True}]

Out[1]=
1
22
333
```

#### FrameStyle (1)

Set the style for the frame:

```wl
In[1]:= Table[Column[{1, 22, 333}, Frame -> True, FrameStyle -> s], {s, {Orange, Thick, Dashed, Directive[Orange, Thick, Dashed]}}]

Out[1]=
{1
22
333, 1
22
333, 1
22
333, 1
22
333}
```

#### ItemSize (2)

Control the size of an item and possibly force linewrapping:

```wl
In[1]:= Table[Column[{1, 22, 333}, ItemSize -> {w, h}, Frame -> True], {h, {1, 2, 3}}, {w, {4, 8, 12}}]//Grid

Out[1]=
|          |          |          |
| -------- | -------- | -------- |
| 1 22 333 | 1 22 333 | 1 22 333 |
| 1 22 333 | 1 22 333 | 1 22 333 |
| 1 22 333 | 1 22 333 | 1 22 333 |
```

---

By setting ``ItemSize``, the content will have a line break:

```wl
In[1]:= t = StringJoin@Riffle[Table["text", {10}], " "];

In[2]:= e = Expand[(x + y) ^ 10];

In[3]:= Column[{e, t}, ItemSize -> {20, Automatic}, Frame -> All]

Out[3]=
x^10 + 10 x^9 y + 45 x^8 y^2 + 120 x^7 y^3 + 210 x^6 y^4 + 252 x^5 y^5 + 210 x^4 y^6 + 120 x^3 y^7 + 45 x^2 y^8 + 10 x y^9 + y^10
"text text text text text text text text text text"
```

#### ItemStyle (4)

Change the overall style:

```wl
In[1]:= Table[Column[{1, 22, 333}, ItemStyle -> s], {s, {Blue, Gray, Purple}}]

Out[1]=
{1
22
333, 1
22
333, 1
22
333}
```

---

Change the style for a specific element:

```wl
In[1]:= Column[{1, 22, 333}, ItemStyle -> {1 -> Purple, 2 -> Red, 3 -> Bold}]

Out[1]=
1
22
333
```

---

Dynamically change the element being styled:

```wl
In[1]:= Slider[Dynamic[x], {1, 3, 1}]

Out[1]= Slider[Dynamic[x], {1, 3, 1}]

In[2]:= Column[{1, 22, 333}, ItemStyle -> {Dynamic[x] -> Large}]

Out[2]=
1
22
333
```

---

Dynamically change the style of a specific element:

```wl
In[1]:= Slider[Dynamic[x]]

Out[1]= Slider[Dynamic[x]]

In[2]:= Column[{1, 22, 333}, ItemStyle -> {3 -> Hue[Dynamic[x]]}]

Out[2]=
1
22
333
```

#### Spacings (1)

Change the spacing between elements:

```wl
In[1]:= Table[Column[{1, 22, 333}, Spacings -> s, Frame -> True], {s, {0, 1, 2, 3, 4, 5}}]

Out[1]=
{1
22
333, 1
22
333, 1
22
333, 1
22
333, 1
22
333, 1
22
333}
```

### Properties & Relations (1)

``Column`` is a special case of ``Grid`` :

```wl
In[1]:= Column[{1, 12, 123}]

Out[1]=
1
12
123

In[2]:= Grid[Transpose[{{1, 12, 123}}], Alignment -> Left]

Out[2]=
|     |
| :-- |
| 1   |
| 12  |
| 123 |
```

## See Also

* [`GraphicsColumn`](https://reference.wolfram.com/language/ref/GraphicsColumn.en.md)
* [`Row`](https://reference.wolfram.com/language/ref/Row.en.md)
* [`Multicolumn`](https://reference.wolfram.com/language/ref/Multicolumn.en.md)
* [`Grid`](https://reference.wolfram.com/language/ref/Grid.en.md)
* [`Labeled`](https://reference.wolfram.com/language/ref/Labeled.en.md)
* [`InsertLinebreaks`](https://reference.wolfram.com/language/ref/InsertLinebreaks.en.md)

## Tech Notes

* [Tables and Matrices](https://reference.wolfram.com/language/tutorial/TextualInputAndOutput.en.md#28366)
* [Grids, Rows, and Columns](https://reference.wolfram.com/language/tutorial/GridsRowsAndColumnsOverview.en.md)
* [String‐Oriented Output Formats](https://reference.wolfram.com/language/tutorial/TextualInputAndOutput.en.md#1899)
* [Formatted Output](https://reference.wolfram.com/language/tutorial/TextualInputAndOutput.en.md#6589676)

## Related Guides

* [Grids & Tables](https://reference.wolfram.com/language/guide/GridsAndTables.en.md)
* [Layout & Tables](https://reference.wolfram.com/language/guide/LayoutAndTables.en.md)
* [Computation with Structured Datasets](https://reference.wolfram.com/language/guide/ComputationWithStructuredDatasets.en.md)
* [`Palettes`](https://reference.wolfram.com/language/guide/Palettes.en.md)
* [Notebook Formatting & Styling](https://reference.wolfram.com/language/guide/NotebookFormattingAndStyling.en.md)
* [Mathematical Typesetting](https://reference.wolfram.com/language/guide/MathematicalTypesetting.en.md)
* [User Interface Structuring & Layout](https://reference.wolfram.com/language/guide/UserInterfaceStructuringAndLayout.en.md)
* [Data Visualization](https://reference.wolfram.com/language/guide/DataVisualization.en.md)
* [Automated Reports](https://reference.wolfram.com/language/guide/AutomatedReports.en.md)
* [Basic Input & Output in Programs](https://reference.wolfram.com/language/guide/BasicInputAndOutputInPrograms.en.md)

## Related Workflows

* [Make a Grid of Output Data](https://reference.wolfram.com/language/workflow/MakeAGridOfOutputData.en.md)
* [Create a Palette](https://reference.wolfram.com/language/workflow/CreateAPalette.en.md)

## Related Links

* [An Elementary Introduction to the Wolfram Language: Displaying Lists](https://www.wolfram.com/language/elementary-introduction/04-displaying-lists.html)
* [An Elementary Introduction to the Wolfram Language: Layout and Display](https://www.wolfram.com/language/elementary-introduction/37-layout-and-display.html)

## History

* [Introduced in 2007 (6.0)](https://reference.wolfram.com/language/guide/SummaryOfNewFeaturesIn60.en.md)