Skip to content

excel chart column

zmworm edited this page Apr 13, 2026 · 17 revisions

Excel: Chart - column

A dedicated page for the column chart type. Column charts display data as vertical bars, ideal for comparing values across categories.

Path: /{SheetName}/chart[N]

See also: Chart - add, Chart - set, bar for the horizontal variant.

Chart type variants

Type string Grouping 3D
column Clustered No
columnStacked Stacked No
columnPercentStacked PercentStacked No
column3d Clustered Yes

Column-specific properties

Gap width

Property Default Notes
gapWidth / gap 150 Space between bar groups (0-500, as % of bar width)
# Tight bars (no gap)
officecli add data.xlsx /Sheet1 --type chart \
  --prop chartType=column --prop gapWidth=0 \
  --prop data="Sales:10,20,30" --prop categories="A,B,C"

# Wide gap
officecli set data.xlsx /Sheet1/chart[1] --prop gapWidth=300

Overlap

Property Default Notes
overlap 0 (clustered), 100 (stacked) Bar overlap (-100 to 100, as % of bar width)

Positive values overlap bars; negative values add space between bars within the same category group.

officecli set data.xlsx /Sheet1/chart[1] --prop overlap=50

Invert if negative

Property Default Notes
invertIfNeg / invertIfNegative false Reverse bar color/direction for negative values
officecli set data.xlsx /Sheet1/chart[1] --prop invertIfNeg=true

Bar shape (3D only)

Property Default Notes
shape / barShape box 3D bar shape: box, cone, cylinder, pyramid
officecli add data.xlsx /Sheet1 --type chart \
  --prop chartType=column3d --prop shape=cylinder \
  --prop data="Q:10,20,30,40" --prop categories="Q1,Q2,Q3,Q4"

Examples

# Basic column chart
officecli add data.xlsx /Sheet1 --type chart \
  --prop chartType=column \
  --prop title="Quarterly Sales" \
  --prop data="East:120,180,210,250;West:90,140,160,200" \
  --prop categories="Q1,Q2,Q3,Q4"

# Stacked column with reference line
officecli add data.xlsx /Sheet1 --type chart \
  --prop chartType=columnStacked \
  --prop title="Revenue Breakdown" \
  --prop data="Product:40,50,60;Service:20,30,40" \
  --prop categories="Q1,Q2,Q3" \
  --prop "referenceLine=80:FF0000:1:dash"

HTML preview support

Feature Preview Notes
Vertical columns Yes
Stacked / percent stacked Yes
Gap width Yes
Data labels Yes Positioned at bar center
Reference lines Yes Horizontal overlays
3D columns Yes Isometric projection
Custom axis scale Yes

See Also

  • Chart - Overview
  • bar - Horizontal variant

Based on OfficeCLI v1.0.43

Clone this wiki locally