charton API / @chart-on/core / index / IndicatorAddOptions
Interface: IndicatorAddOptions
Defined in: packages/core/src/indicators/manager.ts:66
Options for adding an indicator: its price scale, whether it shows in the legend and is saved, whether limits apply, and where it draws.
Properties
legend?
optionallegend?:boolean
Defined in: packages/core/src/indicators/manager.ts:73
false leaves the indicator out of the legend. Default true.
persist?
optionalpersist?:boolean
Defined in: packages/core/src/indicators/manager.ts:81
false leaves it out of serialize() and saved layouts, e.g. for indicators the app adds itself. Default true.
placement?
optionalplacement?:"overlay"|"pane"
Defined in: packages/core/src/indicators/manager.ts:79
Where a definition with placement: 'either' draws: on the price pane ('overlay', the default) or in a new pane ('pane'). Ignored for definitions with a fixed placement.
priceScale?
optionalpriceScale?:string
Defined in: packages/core/src/indicators/manager.ts:71
Price scale id in the indicator's pane, overriding the definition's priceScale (default 'right'). Kept in saved state.
renderer?
optionalrenderer?:"canvas"|"gpu"
Defined in: packages/core/src/indicators/manager.ts:95
Where line plots and the fills between them are drawn (default 'gpu'). 'gpu' draws them with WebGL2, which costs the CPU far less with many indicators, long histories or frequent redraws. They then draw below every series drawn on the canvas, like candles do; 'canvas' strokes them with the 2D canvas instead. Copies made by duplicate keep it; saved state does not.
restricted?
optionalrestricted?:boolean
Defined in: packages/core/src/indicators/manager.ts:86
false skips the access rule and the indicator limit, for indicators the app adds itself. The indicator still counts towards the limit. Default true.