
Excel Report Generator
This is a solid automation tool for generating Excel reports from CSVs, databases, or pandas DataFrames using openpyxl and xlsxwriter. It handles the full workflow: data processing, multi-sheet creation, styling headers and cells, adding charts, applying conditional formatting, and even template-based fills. The implementation guide walks through actual code for common patterns like color scales, data validation dropdowns, and auto-adjusting column widths. Best for recurring business reports, data exports, or KPI dashboards where you need formatted spreadsheets without manually opening Excel. The write-only mode optimization for large datasets is a nice touch. It includes practical error handling and troubleshooting for issues like encoding problems and slow generation.
- skills.sh installs
- 394
- GitHub stars
- 294
- last updated
- Aug 21, 2026
Install
$ npx -y skills add wwwzhouhui/skills_collection --skill excel-report-generator --agent claude-codeInstalls into .claude/skills of the current project.
Files
Excel Report Generator
自动化 Excel 报表生成工具,支持从多种数据源生成专业的 Excel 报告。
功能概述
这个 Skill 可以帮助你:
- 📊 从 CSV、数据库或 Python 数据结构生成 Excel 报表
- 📈 创建包含图表、格式化和公式的数据分析报告
- 📋 基于模板填充数据生成业务报告
- 💾 将系统数据批量导出为格式化的 Excel 文件
- 🎨 应用专业的样式、颜色和条件格式
核心技术栈
- pandas: 数据处理和分析
- openpyxl: Excel 文件读写和格式化
- xlsxwriter: 高级图表和格式支持(可选)
使用场景
1. 数据分析报表
从原始数据生成包含统计分析、透视表和可视化图表的综合报告。
示例请求:
- "帮我从这个 CSV 生成销售分析报表"
- "创建一个包含月度趋势图的数据分析 Excel"
- "生成带有统计汇总的财务报表"
2. 业务报告
定期生成标准化的业务报告,如销售报告、KPI 仪表板等。
示例请求:
- "生成本月的销售业绩报告"
- "创建 KPI 跟踪报表"
- "导出季度业务总结 Excel"
3. 数据导出
将数据库查询结果或系统数据导出为格式化的 Excel 文件。
示例请求:
- "把用户数据导出到 Excel"
- "将数据库查询结果保存为 Excel 文件"
- "导出多个工作表的数据集"
4. 模板填充
基于预定义的 Excel 模板填充动态数据。
示例请求:
- "使用这个模板生成报告"
- "填充 Excel 模板中的数据"
- "批量生成基于模板的发票"
使用方法
基本工作流程
- 准备数据源: CSV 文件、pandas DataFrame、数据库连接或 Python 字典
- 定义报表需求: 描述所需的格式、图表、样式
- 生成报表: 自动创建格式化的 Excel 文件
- 验证输出: 检查生成的文件是否符合要求
命令示例
从 CSV 生成报表:
请从 sales_data.csv 生成一个销售分析报表,包含:
- 按产品分类的销售汇总
- 月度销售趋势图
- Top 10 产品排名
从 DataFrame 生成报表:
我有一个 pandas DataFrame,帮我生成 Excel 报表,包括:
- 数据透视表
- 条件格式高亮异常值
- 自动筛选和冻结首行
Sponsors
Details
- Repository
- github.com/wwwzhouhui/skills_collection
- Categories
- Data Science & ML, Automation & Workflows, Python, Office & Documents
- First seen
- Jun 3, 2026