【问题标题】:Python Plotly - how to return current position of rangeslider?Python Plotly - 如何返回范围滑块的当前位置?
【发布时间】:2019-03-03 20:29:56
【问题描述】:

我喜欢在股票图表中选择特定的兴趣范围(例如 1 年的时间段),然后按一下按钮将当前标记的开始和结束位置作为列表返回。可以选择将数据写入 csv 文件。 范围数据稍后用于为机器学习准备数据集。

有没有机会用 plotly 做到这一点?

范围滑块:https://plot.ly/python/range-slider/ 自定义按钮:https://plot.ly/python/custom-buttons/#methods

【问题讨论】:

    标签: python plotly-python


    【解决方案1】:

    所以基本上你需要一个事件监听器,而且目前似乎不支持开箱即用,请参阅:

    https://github.com/plotly/plotly.js/issues/2719

    但也许这样的解决方法:plotly rangeslider how to determine if range is selected

    将完成这项工作。然而,让它在 Python 中工作似乎很棘手......

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多