Skip to content
EliteChart

computeLineBreak

Documentation


Documentation / @elitechart/core / computeLineBreak

code
function computeLineBreak(bars, opts?): readonly Bar[];

Defined in: series/line-break.ts:283

Batch transform — converts an entire raw OHLCV series into Line Break lines. Returns Bar[] so the existing painter pipeline consumes them unchanged.

Empty input → empty output. Single-bar input → empty output (need at least 2 bars to evaluate any threshold).

Parameters

bars

readonly Bar[]

opts?

LineBreakOptions = {}

Returns

readonly Bar[]

Example

code
import { computeLineBreak } from '@elitechart/core';
const lines = computeLineBreak(bars, { lineCount: 3 });