1

I am using Plotly OHLC charts with Jupyter Notebook. Currently, Plotly offers some interactive controls on its OHLC charts:

enter image description here

While Plotly is doing a good job here, these controls are not what most the trades expect. The lack of standard OHLC controls lead to expectation mismanagement and poor UX. Thus, I would like to customize these controls.

E.g.

  • Change the default action to pan instead of section selection zoom
  • Make rubber band zoom controls for both X and Y axis
  • Make the toolbox visible always and change the tool box controls

My question is

  • What would be the starting point to customize Plotly JavaScript code to make any enhancement or new controls
  • If we assume the current OHLC is too inflexible to customize and has to be rewritten, what is the process to add new widgets to Plotly Python (and JavaScript libraries)
Derek O
  • 16,770
  • 4
  • 24
  • 43
Mikko Ohtamaa
  • 82,057
  • 50
  • 264
  • 435
  • Can the solution be in Plotly and you can do it Plotly.js? – Hamzah Dec 07 '22 at 09:22
  • I don't expect to be able to create UI logic code for JavaScript controls in Python code. It is the wrong layer. – Mikko Ohtamaa Dec 07 '22 at 10:13
  • 1
    Have you considered the use of Highcharts? With or without Jupyter Highcharts may be more of what you're looking for. I'd suggest checking out what it does for JS, then if interested, look at the Python interfaces. For notebook-specific, look at `pandas_highcharts`. Otherwise, you can look at `justpy`. – Kat Dec 07 '22 at 14:13
  • 1
    @Kat - Highcharts is not open source, so it is not a business interest to consider it. I'd rather pay someone $2k to just patch Plotly for me instead of licensing Highcharts. – Mikko Ohtamaa Dec 07 '22 at 15:45
  • 1
    Ahhh, okay, didn't really it was for business use. Plotly does have [things like this](https://gistpreview.github.io/?c3f0557b0bb87f6b410d6d49e1124bda). Is that sort of what you're looking for? [You can see the JS here.](https://gist.github.com/mzechmeister/c3f0557b0bb87f6b410d6d49e1124bda) – Kat Dec 07 '22 at 17:10

0 Answers0