Kagi chart is a line chart changing direction when the price moves by a certain amount. It is constructed using a series of connected, time-independent vertical lines. Kagi charts give information on supply and demand forces and price reversals.

Hierarchy

  • Kagi

Constructors

  • Parameters

    • priceChart: TradingChart
    • chart: ChartXY<UIBackground>
    • currentData: XOHLC[]
    • dates: string[]
    • kagiBase: BaseType = BaseType.Close
    • reversalAmount: number = 2
    • atrPeriodCount: number = 14
    • colorThick: Color = ...
    • colorThin: Color = ...
    • lineWidth: number = 2

    Returns Kagi

Methods

  • Solves the Kagi value at the current cursor position.

    Parameters

    • xValue: number

      Cursor X-value.

    Returns number

    Kagi price value at mouse position.

  • Sets the number of time periods (n) used to calculate the Average True Range (ATR). Used when Kagi chart is based on ATR.

    Parameters

    • newPeriodCount: number

      New period count.

    Returns void

  • Sets which values the Kagi chart is based on.

    Parameters

    Returns void

  • Sets the width of the Kagi lines. Thick lines will be slightly thicker than the given value.

    Parameters

    • newWidth: number

      New line width.

    Returns void

  • Sets the reversal amount for the Kagi chart. The line will change direction when there is a price reversal of at least this amount.

    Parameters

    • boxSize: number

      New reversal amount.

    Returns void

  • Sets the color of the uptrend line.

    Parameters

    • newColor: string

      New line color as string, should be in HEX format e.g. #FFFFFF.

    Returns void

  • Sets the color of the downtrend line.

    Parameters

    • newColor: string

      New line color as string, should be in HEX format e.g. #FFFFFF.

    Returns void