[英]how to draw line chart with date fomat on excel using openpyxl of python
I draw a line chart on excel using openpyxl 我使用openpyxl在excel上绘制折线图
In excel sheet: 在Excel工作表中:
date value
"2015-05-01" | 0.1
"2015-05-02" | 0.2
"2015-05-03" | 0.3
"2015-05-04" | 0.4
But it gives integer format for date data like "45612"... How could I draw line chart with date format? 但是它为日期数据提供了整数格式,例如“ 45612” ...如何绘制具有日期格式的折线图? (date is x-axis, and value is y-axis)
(日期是x轴,值是y轴)
使用类似这样的内容: chart.x_axis.number_format = 'yyyy-mm-dd'
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.