efenadir
Posts: 31
Joined: Sat Jul 10, 2021 6:32 pm

Color of candlestick chart

Hi,

I am using Stock Chart with GUI. I want to change the candlestick chart colors to red and green from the default colors, but I also wanted to change the line chart color as well. In the demo, it is yellow. But when I set the line color to yellow and switch to candlestick chart on GUI Tools, some parts of the candlestick chart is also yellow which I don't want to.

Demo: https://codesandbox.io/s/data-grouping- ... c/index.js
candlestick.png
candlestick.png (66.97 KiB) Viewed 754 times
I want yellow parts to be red.

Thank you for your consideration.
mateusz.b
Posts: 2006
Joined: Tue Jul 13, 2021 11:34 am

Re: Color of candlestick chart

Hello efenadir,

Thanks for contacting us with your question.

Because these two series doesn't share any colors, I think it would be a good idea to set color per series type, instead of setting it globally. To do so, I defined yellow color only for line series.
Demo: https://codesandbox.io/s/data-grouping- ... rked-msn7q

Let me know what do you think about this approach and feel free to ask any further questions.
Best regards!
Mateusz Bernacik
Highcharts Developer
efenadir
Posts: 31
Joined: Sat Jul 10, 2021 6:32 pm

Re: Color of candlestick chart

Hi mateusz.b,

That really makes sense... Thank you!

Kind regards.
mateusz.b
Posts: 2006
Joined: Tue Jul 13, 2021 11:34 am

Re: Color of candlestick chart

You're welcome! In case of any further questions, feel free to contact us again.
Mateusz Bernacik
Highcharts Developer

Return to “Highcharts Stock”