-
Notifications
You must be signed in to change notification settings - Fork 465
excel chart combo
A dedicated page for the combo chart type. Combo charts overlay
multiple chart types (column + line, column + area, etc.) on shared
axes, enabling dual-metric visualizations like "revenue bars with
growth-rate line".
Path: /{SheetName}/chart[N]
Add command shape:
officecli add data.xlsx /Sheet1 --type chart \
--prop chartType=combo \
--prop comboSplit=1 \
--prop title="Revenue vs Growth" \
--prop series1="Revenue:100,200,300,400" \
--prop series2="Growth %:5,8,12,15" \
--prop categories="Q1,Q2,Q3,Q4" \
--prop secondaryAxis=2 \
<styling props>See also: Chart - add, Chart - set.
| Property | Default | Notes |
|---|---|---|
comboSplit |
— | Number of series rendered as bars; remaining become lines |
# First series as bars, second as line
officecli add data.xlsx /Sheet1 --type chart \
--prop chartType=combo \
--prop comboSplit=1 \
--prop series1="Revenue:100,200,300,400" \
--prop series2="Growth %:5,8,12,15" \
--prop categories="Q1,Q2,Q3,Q4"| Property | Default | Notes |
|---|---|---|
comboTypes / combo.types
|
— | Per-series chart types: comma-separated list |
Rebuilds the entire chart structure to assign each series its own
chart type. Supported per-series types: column, bar, line, area.
# Remap: first two series as columns, third as line
officecli set data.xlsx /Sheet1/chart[1] --prop combotypes="column,column,line"Combo charts commonly pair a secondary Y axis for the line series:
officecli add data.xlsx /Sheet1 --type chart \
--prop chartType=combo \
--prop comboSplit=1 \
--prop series1="Revenue:100,200,300" \
--prop series2="Margin %:15,18,22" \
--prop categories="Q1,Q2,Q3" \
--prop secondaryAxis=2A chart is identified as combo when the plot area contains more than
one chart type element (e.g. both c:barChart and c:lineChart).
| Property | Default | Notes |
|---|---|---|
title |
— | Chart title text |
title.font / titleFont
|
— | Font family |
title.size / titleSize
|
— | Font size (pt) |
title.color / titleColor
|
— | Font color (hex) |
title.bold / titleBold
|
— | Bold (true/false) |
title.glow / titleGlow
|
— | Glow: "COLOR-RADIUS-OPACITY" or "none"
|
title.shadow / titleShadow
|
— | Shadow: "COLOR-BLUR-ANGLE-DIST-OPACITY" or "none"
|
| Property | Default | Notes |
|---|---|---|
legend |
true |
Position: top, bottom, left, right, none
|
legend.overlay |
false |
Float legend on top of the chart |
legendFont / legend.font
|
— | "size:color:fontname" |
| Property | Default | Notes |
|---|---|---|
axisMin / min
|
(auto) | Value axis lower bound |
axisMax / max
|
(auto) | Value axis upper bound |
majorUnit |
(auto) | Major gridline / tick interval |
minorUnit |
(auto) | Minor gridline / tick interval |
axisNumFmt / axisNumberFormat
|
General |
Number format for tick labels (e.g. "$#,##0", "0%") |
# Lock primary Y axis range
officecli add data.xlsx /Sheet1 --type chart \
--prop chartType=combo \
--prop comboSplit=1 \
--prop series1="Revenue:100,200,300,400" \
--prop series2="Growth %:5,8,12,15" \
--prop categories="Q1,Q2,Q3,Q4" \
--prop secondaryAxis=2 \
--prop axisMin=0 --prop axisMax=500 --prop majorUnit=100| Property | Default | Notes |
|---|---|---|
logBase / logScale
|
— | Logarithmic scale base (e.g. 10) |
| Property | Default | Notes |
|---|---|---|
axisOrientation / axisReverse
|
minMax |
Set to maxMin or true to flip the Y axis |
| Property | Default | Notes |
|---|---|---|
secondaryAxis / secondary
|
— | Comma-separated 1-based series indices for secondary Y axis |
# Revenue on left axis, growth rate on right axis
officecli add data.xlsx /Sheet1 --type chart \
--prop chartType=combo \
--prop comboSplit=1 \
--prop series1="Revenue:100,200,300,400" \
--prop series2="Growth %:5,8,12,15" \
--prop categories="Q1,Q2,Q3,Q4" \
--prop secondaryAxis=2| Property | Default | Notes |
|---|---|---|
dispUnits / displayUnits
|
— |
thousands, millions, billions, etc. |
| Property | Default | Notes |
|---|---|---|
axisVisible / axis.visible
|
true |
Show/hide both axes |
axisLine / axis.line
|
— | Value axis line: "color:width:dash"
|
catAxisLine |
— | Category axis line: "color:width:dash"
|
majorTickMark / majorTick
|
— |
out, in, cross, none
|
minorTickMark / minorTick
|
— | Same as major tick |
tickLabelPos |
nextTo |
nextTo, high, low, none
|
| Property | Default | Notes |
|---|---|---|
gridlines / majorGridlines
|
true |
Toggle or configure: true, false/none, or "color:widthPt:dash"
|
minorGridlines |
false |
Same format as gridlines
|
# Custom gridlines for combo chart
officecli add data.xlsx /Sheet1 --type chart \
--prop chartType=combo \
--prop comboSplit=1 \
--prop series1="Revenue:100,200,300" \
--prop series2="Growth:5,8,12" \
--prop categories="Q1,Q2,Q3" \
--prop "gridlines=D0D0D0:0.5:solid" \
--prop "minorGridlines=EEEEEE:0.3:sysDot"| Property | Default | Notes |
|---|---|---|
referenceLine / refLine
|
— |
value or "value:color:width:dash"
|
Reference lines are horizontal overlays drawn at a constant value. They appear in the legend and are rendered in the HTML preview with the correct dash pattern.
# Target line at 300 — red, dashed
officecli add data.xlsx /Sheet1 --type chart \
--prop chartType=combo \
--prop comboSplit=1 \
--prop series1="Revenue:100,200,300,400" \
--prop series2="Growth:5,8,12,15" \
--prop categories="Q1,Q2,Q3,Q4" \
--prop "referenceLine=300:FF0000:1.5:dash"| Property | Default | Notes |
|---|---|---|
plotFill / plotAreaFill
|
— | Plot area background: hex, gradient "C1-C2[:angle]", or "none"
|
chartFill / chartAreaFill
|
— | Chart area background |
plotArea.border / plotBorder
|
— | Plot area outline: "color:width:dash" or "none"
|
chartArea.border / chartBorder
|
— | Chart area outline |
| Property | Default | Notes |
|---|---|---|
series.shadow / seriesShadow
|
— |
"COLOR-BLUR-ANGLE-DIST-OPACITY" or "none"
|
series.outline / seriesOutline
|
— |
"COLOR-WIDTH" e.g. "FFFFFF-0.5" or "none"
|
| Property | Default | Notes |
|---|---|---|
dataLabels |
false |
Toggle data labels |
labelPos / labelPosition
|
— | Position: center, insideEnd, insideBase, outsideEnd, top, bottom, left, right, bestFit
|
labelFont |
— | "size:color:bold" |
dataLabel{N}.text |
— | Custom text for individual label |
dataLabel{N}.x/y/w/h |
— | Manual layout of individual label |
dataLabel{N}.delete |
— | Hide individual label |
dataLabels.separator |
— | Separator between label parts |
dataLabels.numFmt |
— | Number format for labels |
| Property | Default | Notes |
|---|---|---|
transparency |
0 | Series transparency (0-100%) |
opacity / alpha
|
100 | Series opacity (0-100%) |
| Property | Default | Notes |
|---|---|---|
x, y
|
0 |
Chart position (column/row index) |
width |
8 |
Chart width (column units) |
height |
15 |
Chart height (row units) |
plotArea.x/y/w/h |
— | Manual plot area layout (0-1 decimal) |
title.x/y/w/h |
— | Manual title layout |
legend.x/y/w/h |
— | Manual legend layout |
| Property | Default | Notes |
|---|---|---|
dispBlanksAs / blanksAs
|
gap |
How blank cells are handled: gap, zero, span/connect
|
| Property | Default | Notes |
|---|---|---|
colorRule / conditionalColor
|
— | Color data points conditionally |
point{N}.color |
— | Individual data point color (hex) |
officecli add data.xlsx /Sheet1 --type chart \
--prop chartType=combo \
--prop comboSplit=2 \
--prop title="Revenue & Margin Analysis" \
--prop title.size=14 --prop title.bold=true \
--prop title.font="Arial" --prop title.color=1F2937 \
--prop series1="Product:120,180,210,250" \
--prop series2="Service:40,60,80,100" \
--prop series3="Margin %:15,18,22,25" \
--prop categories="Q1,Q2,Q3,Q4" \
--prop secondaryAxis=3 \
--prop colors="4472C4,ED7D31,70AD47" \
--prop "gridlines=E5E7EB:0.5:solid" \
--prop "referenceLine=200:FF0000:1:dash" \
--prop plotFill=FAFBFC \
--prop legend=bottom \
--prop "legendfont=9:6B7280:Arial" \
--prop x=0 --prop y=0 --prop width=14 --prop height=20| Feature | Preview | Notes |
|---|---|---|
| Bar + line overlay | Yes | Composite rendering |
| Shared axes | Yes | |
| Secondary axis | Yes | |
| Data labels | Yes | Value text at series points |
| Reference lines | Yes | Horizontal overlays |
| Custom axis scale | Yes | axisMin/axisMax/majorUnit |
| Gridlines | Yes | Color, width, dash from OOXML |
| Shadow effects | No | Decorative; not rendered |
| Glow effects | No | Decorative; not rendered |
-
comboSplitis creation-only. You cannot change the split after creation; usecomboTypesviasetto remap series types. -
Detection is heuristic. A chart with two chart type elements
in the plot area is identified as combo, even if both are the same
type (e.g. two
c:barChartelements).
# List all charts
officecli query data.xlsx chart
# Inspect a specific chart
officecli get data.xlsx "/Sheet1/chart[1]"
# Render to HTML preview
officecli view data.xlsx html > preview.html- Chart - Overview of chart operations
- Chart add - Generic chart add (all types)
- Chart set - Modify existing charts
- Chart get - Read back chart properties
Based on OfficeCLI v1.0.64