Treemap

Enterprise SaaS Spending Breakdown

Dark-themed treemap showing enterprise software spending distribution across different SaaS categories.

Output
Enterprise SaaS Spending Breakdown
Python
import matplotlib.pyplot as plt
import squarify
import numpy as np

# SaaS spending (annual in thousands)
labels = ['CRM/Sales', 'Cloud Infra', 'HR/Payroll', 'Security',
          'Collaboration', 'Analytics', 'DevOps', 'Marketing',
          'Finance/ERP', 'Support']
sizes = [185, 320, 95, 145, 78, 88, 125, 110, 165, 55]
total = sum(sizes)

# CLAUDE.md colors
colors = ['#F5276C', '#27D3F5', '#6CF527', '#C82909', '#5314E6',
          '#F5B027', '#276CF5', '#F54927', '#27F5B0', '#F527B0']

fig, ax = plt.subplots(figsize=(12, 8), facecolor='#0a0a0f')
ax.set_facecolor('#0a0a0f')

pct = [s/total*100 for s in sizes]
squarify.plot(sizes=sizes, 
              label=[f'{l}\n${s}K ({p:.1f}%)' for l, s, p in zip(labels, sizes, pct)],
              color=colors, alpha=0.85, ax=ax,
              text_kwargs={'fontsize': 9, 'color': 'white', 'fontweight': 'bold'})

ax.axis('off')
ax.set_title(f'Annual SaaS Spending - ${total/1000:.2f}M', 
             fontsize=18, color='#f8fafc', fontweight='bold', pad=20)

plt.tight_layout()
plt.show()
Library

Matplotlib

Category

Part-to-Whole

Did this help you?

Support PyLucid to keep it free & growing

Support