values='aqi',
index='年月',
columns='日期')
# 转化后部分月份不存在部分日期默认为nan值,需要转化为数字格式...效果
3.2. plotly的热力图绘制
对于plotly来说,plotly.express可以直接将满足条件格式的dataframe数据用px.imshow()绘制,不过试了很久暂时没学会怎么方便的将数值显示在热力图上...;
为了更好的在热力图上显示数值,需要将原来的float转化为int,nan转化为空字符。...https://matplotlib.org/stable/gallery/images_contours_and_fields/image_annotated_heatmap.html
plotly元素周期表绘制案例...元素周期表
# Add Periodic Table Data
symbol = [['H', '', '', '', '', '', '', '', '', '', '', '', '', '', '