I use the .to_excel method of pandas to write a DataFrame as an Excel workbook.
This works nice even for multi-index DataFrames as index cells become merged.
When using the pure XlsxWriter I can apply formats to cells what also works nice.
However I couldn't find a way to do the same with the pandas method. Just passing a dict with column names and styles would be most intuitive.
Is there any way to do so?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…