Appearance
@shbernal/pptxgenjs / index / IOptsChartData
Interface: IOptsChartData
Defined in: core-interfaces.ts:2141
Extends
Properties
_dataIndex?
optional_dataIndex?:number
Defined in: core-interfaces.ts:2004
Inherited from
customLabels?
optionalcustomLabels?:string[]
Defined in: core-interfaces.ts:2034
Custom text label per data point, replacing the auto-generated value label. Index aligns with values[]. Empty string or missing entries fall back to the chart-level label settings. Supported for BAR, LINE, AREA, RADAR, PIE, and DOUGHNUT chart types.
Example
ts
['Low', '', 'High'] // only points 0 and 2 get custom labelsInherited from
errorBars?
optionalerrorBars?:ChartErrorBarOptions|ChartErrorBarOptions[]
Defined in: core-interfaces.ts:2057
Error bars for this series (<c:errBars>).
- Supported for BAR, BAR3D, LINE, AREA, and SCATTER chart types (RADAR has no error bars in the schema).
- Pass a single config, or an array to draw both X and Y error bars (SCATTER/AREA only; BAR/LINE use the first entry).
Examples
ts
{ valueType: 'percentage', value: 5 } // ±5% error barsts
{ valueType: 'fixedVal', value: 2, barType: 'plus', noEndCap: true }ts
{ valueType: 'cust', plusValues: [1, 2, 1], minusValues: [0.5, 1, 0.5] }Since
v6.0.0
Inherited from
labels?
optionallabels?:string[][]
Defined in: core-interfaces.ts:2142
category labels
Examples
ts
['Year 2000', 'Year 2010', 'Year 2020'] // single-level category axes labelsts
[['Year 2000', 'Year 2010', 'Year 2020'], ['Decades', '', '']] // multi-level category axes labelsSince
labels string[][] type added v3.11.0
Overrides
name?
optionalname?:string
Defined in: core-interfaces.ts:2017
series name
Example
ts
'Locations'Inherited from
pointStyles?
optionalpointStyles?:ChartDataPointStyle[]
Defined in: core-interfaces.ts:2047
Per-data-point visual overrides (border / fill), index-aligned with values[]. Empty ({}) or missing entries fall back to series/chart styling. Supported for BAR, LINE, AREA, SCATTER, PIE, and DOUGHNUT chart types.
Example
ts
pointStyles: [
{ border: { pt: 2, color: 'FF0000' } }, // point 0: red 2pt border
{}, // point 1: default
{ fill: '00B050', border: { type: 'dash', color: '404040' } }, // point 2
]Since
v5.3.0
Inherited from
sizes?
optionalsizes?:number[]
Defined in: core-interfaces.ts:2022
bubble sizes
Example
ts
[5, 1, 5, 1]Inherited from
values?
optionalvalues?:number[]
Defined in: core-interfaces.ts:2027
category values
Example
ts
[2000, 2010, 2020]