在多窗格Highstock图表中仅为一个窗格设置背景色

问题描述:

在此示例中: http://www.highcharts.com/stock/demo/candlestick-and-volume ,是否可以设置第二个窗格的背景颜色?

In this example: http://www.highcharts.com/stock/demo/candlestick-and-volume, is there a way to set the background color of the second pane?

例如,如果在图表定义中添加 plotBackgroundColor:'#FCFFC5',则两个窗格都将变为黄色.

For example, if you add plotBackgroundColor: '#FCFFC5' to the chart definition, then both panes become yellow.

是否可以仅将第二个(下部)窗格设为黄色?

Is it possible to make only the second (lower) pane yellow?

可以使用plotBands在第二个窗格中更改特定范围的背景颜色.

it's possible to change the background color for a specific range in your second pane using plotBands.

例如yAxis:{[...plotBands:{color:'#f7d724',from:-50,to:50},...]}

e.g. yAxis : {[ ... plotBands : {color : '#f7d724', from : -50, to : 50}, ... ]}