Working with Spreadsheets
Quick Start
from openpyxl import Workbook
wb = Workbook()
sheet = wb.active
sheet['A1'] = 'Revenue'
sheet['B1'] = 1000
sheet['B2'] = '=B1*1.1' # Use formulas, not hardcoded values!
wb.save('output.xlsx')
Critical Rule: Use Formulas, Not Hardcoded Values
Always use Excel formulas instead of calculating in Python.
# WRONG - Hardcoding calculated values
total = df['Sales'].sum()
sheet['B10'] = total # Hardco
[Description truncada. Veja o README completo no GitHub.]