问题描述
目前我可以
我想跳过第2步,将生成的图像直接放入excel。这可能吗?
输入:
writer = pd.ExcelWriter('test',engine='xlsxwriter')
for i in range(.....shape[1]):
plt.figure()
fig,ax = plt.subplots(constrained_layout=True)
.
.
.
plt.savefig(f'{plot_l[i]}.jpg')
plt.close()
worksheet = workbook.add_worksheet(name='graphs')
.
.
.
for i,image in enumerate(l):
worksheet.insert_image(....)
df1.to_excel(writer,sheet_name='test1'...)
df2.to_excel(writer,sheet_name='test2'...)
workbook.close()
writer.save()
输出:
DuplicateWorksheetName: Sheetname 'plots',with case ignored,is already in use.
所需的输出:
擅长使用工作表test1
,test2
和plots
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)