简体   繁体   English

Plotly x轴成型

[英]Plotly x-axis formating

Is there a way to the show annual dates on the xaxis of a python plotly plot.有没有办法在 python plotly plot 的 xaxis 上显示年度日期。 Right now it seems that there are too many ticks which form this dark bar at the bottom.现在似乎有太多的刻度线在底部形成了这个黑条。 Thanks in advance.提前致谢。 Plot Plot

It seems like your dates are not in the right format.看来您的日期格式不正确。 Try formatting them to a datetime object.尝试将它们格式化为日期时间 object。 For example using the pandas function pandas.to_datetime .例如使用 pandas function pandas.to_datetime Documentation for pandas.to_datetime. pandas.to_datetime 的文档。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM