skills/autumnsgrove/xlsx/SKILL.md
Comprehensive Excel spreadsheet creation, editing, and analysis with support for formulas, formatting, charts, data analysis, and visualization. Use when working with .xlsx, .xlsm, .csv files for: (1) Creating spreadsheets with formulas and formatting, (2) Reading/analyzing data, (3) Modifying existing spreadsheets while preserving formulas, (4) Creating charts and visualizations, (5) Data transformation and analysis, (6) Multi-worksheet operations
npx skillsauth add aiskillstore/marketplace xlsxInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
This skill provides comprehensive capabilities for working with Excel spreadsheets programmatically using Python. It covers everything from basic file operations to advanced data analysis, formula management, chart creation, and formatting.
The primary library is openpyxl for full Excel file manipulation, supplemented by pandas for data analysis tasks.
# Primary library
pip install openpyxl
# For data analysis
pip install pandas openpyxl
# Or with uv
uv pip install openpyxl pandas
from openpyxl import Workbook
from openpyxl.styles import Font, PatternFill, Alignment
from openpyxl.utils import get_column_letter
# Create new workbook
wb = Workbook()
ws = wb.active
ws.title = "Sales Report"
# Add headers with formatting
headers = ["Product", "Q1", "Q2", "Q3", "Q4", "Total"]
header_fill = PatternFill(start_color="4472C4", end_color="4472C4", fill_type="solid")
header_font = Font(color="FFFFFF", bold=True)
for col, header in enumerate(headers, start=1):
cell = ws.cell(row=1, column=col, value=header)
cell.fill = header_fill
cell.font = header_font
cell.alignment = Alignment(horizontal="center")
# Add data
data = [
["Product A", 1000, 1200, 1100, 1300],
["Product B", 800, 900, 950, 1000],
["Product C", 1500, 1400, 1600, 1700]
]
for row_idx, row_data in enumerate(data, start=2):
for col_idx, value in enumerate(row_data, start=1):
ws.cell(row=row_idx, column=col_idx, value=value)
# Add formulas for totals
for row in range(2, len(data) + 2):
formula = f"=SUM(B{row}:E{row})"
ws.cell(row=row, column=6, value=formula)
# Adjust column widths
for col in range(1, 7):
ws.column_dimensions[get_column_letter(col)].width = 12
# Save workbook
wb.save("sales_report.xlsx")
from openpyxl import load_workbook
# Load existing workbook
wb = load_workbook('data.xlsx', data_only=True) # data_only=True evaluates formulas
ws = wb.active
# Method 1: Iterate through all rows
for row in ws.iter_rows(min_row=2, values_only=True):
print(row)
# Method 2: Read specific cells
value = ws['A1'].value
value = ws.cell(row=2, column=2).value
# Method 3: Read range
for row in ws['B2':'D5']:
for cell in row:
print(cell.value, end=' ')
print()
# Calculate statistics
values = [cell.value for cell in ws['B'][1:] if isinstance(cell.value, (int, float))]
if values:
print(f"Sum: {sum(values)}")
print(f"Average: {sum(values) / len(values):.2f}")
wb.close()
from openpyxl import load_workbook
from openpyxl.styles import Font
# Load workbook WITHOUT data_only to preserve formulas
wb = load_workbook('existing_report.xlsx')
ws = wb['Sales']
# Update values (formulas will recalculate when opened in Excel)
ws['B2'] = 1500
ws['C2'] = 1650
# Add new row with data and formulas
new_row = ws.max_row + 1
ws[f'A{new_row}'] = "Product D"
ws[f'B{new_row}'] = 900
ws[f'C{new_row}'] = 1000
ws[f'D{new_row}'] = 1100
ws[f'E{new_row}'] = 1200
ws[f'F{new_row}'] = f"=SUM(B{new_row}:E{new_row})" # Add formula
# Apply formatting to new row
for col in range(1, 7):
cell = ws.cell(row=new_row, column=col)
if col == 1:
cell.font = Font(bold=True)
# Save changes
wb.save('existing_report.xlsx')
import pandas as pd
from openpyxl import load_workbook
from openpyxl.styles import Font, PatternFill
# Step 1: Read and analyze data with pandas
df = pd.read_excel('sales_data.xlsx')
# Perform analysis
summary = df.groupby('Product').agg({
'Sales': ['sum', 'mean', 'count'],
'Profit': 'sum'
}).round(2)
summary.columns = ['Total Sales', 'Avg Sales', 'Transactions', 'Total Profit']
# Step 2: Write results to new Excel file
with pd.ExcelWriter('sales_analysis.xlsx', engine='openpyxl') as writer:
df.to_excel(writer, sheet_name='Raw Data', index=False)
summary.to_excel(writer, sheet_name='Summary')
# Step 3: Enhance with openpyxl formatting
wb = load_workbook('sales_analysis.xlsx')
ws = wb['Summary']
header_fill = PatternFill(start_color="366092", end_color="366092", fill_type="solid")
header_font = Font(color="FFFFFF", bold=True)
for cell in ws[1]:
cell.fill = header_fill
cell.font = header_font
wb.save('sales_analysis.xlsx')
data_only=True when loading files if you need to preserve formulasws.append()read_only=True modewrite_only=True modewb.close()datetime objects for dates, not stringscell.number_format = 'mm/dd/yyyy'from openpyxl import Workbook, load_workbook
# Create workbook
wb = Workbook()
ws = wb.active
# Read cell
value = ws['A1'].value
value = ws.cell(row=1, column=1).value
# Write cell
ws['A1'] = "Hello"
ws.cell(row=1, column=1, value="Hello")
# Write formula
ws['C1'] = "=A1+B1"
# Add row
ws.append([1, 2, 3])
# Save and close
wb.save('output.xlsx')
wb.close()
from openpyxl import Workbook, load_workbook
from openpyxl.styles import Font, PatternFill, Border, Side, Alignment
from openpyxl.chart import LineChart, BarChart, PieChart, Reference
from openpyxl.utils import get_column_letter
from openpyxl.data_validation import DataValidation
from openpyxl.formatting.rule import ColorScaleRule, CellIsRule
Add visualizations to your spreadsheets. See examples/workflow-examples.md for complete chart creation workflow including line charts, bar charts, and pie charts.
Apply visual formatting based on cell values. See examples/workflow-examples.md for color scales, icon sets, and rule-based formatting.
Create dropdown lists and input constraints. See examples/workflow-examples.md for dropdown lists, numeric ranges, and date validation.
Work with multiple worksheets and cross-sheet formulas. See examples/workflow-examples.md for complete multi-sheet workflow.
Create professional financial statements. See examples/financial-report.md for a complete income statement example with dynamic formulas.
Transform CSV data into formatted Excel reports. See examples/data-transformation.md for pandas integration and pivot table creation.
Build executive dashboards with multiple charts. See examples/dashboard-creation.md for comprehensive dashboard with KPIs and visualizations.
The scripts/ directory provides utility functions for common operations:
from scripts.excel_helper import (
create_workbook,
read_excel_data,
add_chart,
apply_formatting,
add_formula,
auto_fit_columns
)
# Create new workbook with data
wb, ws = create_workbook("Sales Report", headers=["Product", "Q1", "Q2"])
# Read data from existing file
data = read_excel_data("data.xlsx", sheet_name="Sheet1")
# Add chart to worksheet
add_chart(ws, chart_type="line", data_range="B2:D10", title="Sales Trend")
# Apply formatting
apply_formatting(ws, cell_range="A1:D1", bold=True, bg_color="4472C4")
# Add formula to range
add_formula(ws, cell="E2", formula="=SUM(B2:D2)", copy_down=10)
# Auto-fit all columns
auto_fit_columns(ws)
wb.save("output.xlsx")
references/library-reference.md for complete openpyxl, pandas, and xlsxwriter documentationreferences/best-practices.md for performance optimization, error handling, and common pitfallsexamples/workflow-examples.md - Charts, conditional formatting, data validation, multi-sheet operationsexamples/financial-report.md - Income statement with dynamic formulasexamples/data-transformation.md - CSV to Excel with pandas integrationexamples/dashboard-creation.md - Multi-chart dashboard with KPIsThis skill enables comprehensive Excel automation including:
Use this skill for any task involving Excel files, from simple data entry to complex financial reports and dashboards.
development
Apple Human Interface Guidelines for content display components. Use this skill when the user asks about charts component, collection view, image view, web view, color well, image well, activity view, lockup, data visualization, content display, displaying images, rendering web content, color pickers, or presenting collections of items in Apple apps. Also use when the user says how should I display charts, what's the best way to show images, should I use a web view, how do I build a grid of items, what component shows media, or how do I present a share sheet. Cross-references: hig-foundations for color/typography/accessibility, hig-patterns for data visualization patterns, hig-components-layout for structural containers, hig-platforms for platform-specific component behavior.
tools
Automate HelpDesk tasks via Rube MCP (Composio): list tickets, manage views, use canned responses, and configure custom fields. Always search tools first for current schemas.
testing
Expert Haskell engineer specializing in advanced type systems, pure functional design, and high-reliability software. Use PROACTIVELY for type-level programming, concurrency, and architecture guidance.
tools
GraphQL gives clients exactly the data they need - no more, no less. One endpoint, typed schema, introspection. But the flexibility that makes it powerful also makes it dangerous. Without proper controls, clients can craft queries that bring down your server. This skill covers schema design, resolvers, DataLoader for N+1 prevention, federation for microservices, and client integration with Apollo/urql. Key insight: GraphQL is a contract. The schema is the API documentation. Design it carefully.