Nikunj14357
Posts: 37
Joined: Tue May 31, 2022 11:22 am

issue in heikinashi color

Screenshot 2022-12-01 at 3.35.36 PM 1.png
Screenshot 2022-12-01 at 3.35.36 PM 1.png (70.44 KiB) Viewed 484 times
Here open is higher then close. but still candle is coloured green. Rest of candles are plotting properly but few candles are getting plot like this. Is this bug in library or am I missing something ?.

Code: Select all

      series: [
        {
          animation: {
            duration: 150
          },
          dataGrouping: { enabled: false },
          lineColor: "#FB1809",
          color: "#FB1809",
          upColor: "#4EA64A",
          upLineColor: "#4EA64A",
          showInLegend: false,
          type: this.stratServerice.chartType as any,
          data: this.mapArray,
        },
kamil.m
Posts: 892
Joined: Thu May 19, 2022 1:33 pm

Re: issue in heikinashi color

Hello there,

Thank you for contacting us.

In general, you are right - if the closing price of a Heikin-Ashi candle is higher than its open, then it should be green (if we choose green to be an "up color"), and the opposite for red (bearish) candles. I tried to see if that happens in our demos, but no luck this time - I couldn't manage to reproduce it.

Would you be able to recreate this issue with your data in an online code editor (i.e JSFiddle) and share it with me here?

Thank you in advance,
Regards!
Kamil Musiałowski
Highcharts Developer
kamil.m
Posts: 892
Joined: Thu May 19, 2022 1:33 pm

Re: issue in heikinashi color

Thank you, you are absolutely right about this one. The candle that you are pointing should be black. The same can be compered with tradingview, where indeed it is a red Heikin-Ashi candle.

Since it is a bug, I'll report it on our GitHub Issues page, so feel free to watch the GH thread for any updates and workarounds.
GitHub Issue: https://github.com/highcharts/highcharts/issues/18088

Sorry for the inconvenience,
Best regards!
Kamil Musiałowski
Highcharts Developer

Return to “Highcharts Stock”