Stream Graph

SaaS Revenue by Category Stream

Stream visualization of SaaS market revenue distribution by software category.

Output
SaaS Revenue by Category Stream
Python
import matplotlib.pyplot as plt
import numpy as np

COLORS = {
    'background': '#0a0a0f',
    'text': '#ffffff',
    'grid': '#333333',
}

np.random.seed(3939)
years = np.arange(2018, 2025)
n = len(years)

crm = 25 + 3 * (years - 2018) + np.random.normal(0, 1, n)
erp = 20 + 2 * (years - 2018) + np.random.normal(0, 1, n)
collaboration = 15 + 4 * (years - 2018) + np.random.normal(0, 1, n)
security = 12 + 2.5 * (years - 2018) + np.random.normal(0, 1, n)
analytics = 10 + 2 * (years - 2018) + np.random.normal(0, 0.5, n)
hr = 8 + 1.5 * (years - 2018) + np.random.normal(0, 0.5, n)

data = [np.clip(d, 1, None) for d in [crm, erp, collaboration, security, analytics, hr]]
colors = ['#27D3F5', '#F5B027', '#6CF527', '#F5276C', '#4927F5', '#F527B0']

fig, ax = plt.subplots(figsize=(14, 6), facecolor=COLORS['background'])
ax.set_facecolor(COLORS['background'])

ax.stackplot(years, *data, colors=colors, alpha=0.85, baseline='sym',
             labels=['CRM', 'ERP', 'Collaboration', 'Security', 'Analytics', 'HR'])

ax.axhline(0, color=COLORS['grid'], linewidth=0.5, alpha=0.5)
ax.set_xlim(2018, 2024)

ax.set_title('SaaS Revenue by Category', color=COLORS['text'], fontsize=14, fontweight='bold', pad=15)
ax.set_xlabel('Year', color=COLORS['text'], fontsize=11)
ax.set_ylabel('Revenue ($ Billions)', color=COLORS['text'], fontsize=11)

ax.legend(loc='upper center', bbox_to_anchor=(0.5, -0.12), frameon=False, 
          labelcolor=COLORS['text'], fontsize=9, ncol=6)

for spine in ax.spines.values():
    spine.set_visible(False)
ax.tick_params(colors=COLORS['text'], labelsize=9)

plt.tight_layout()
plt.subplots_adjust(bottom=0.18)
plt.show()
Library

Matplotlib

Category

Time Series

Did this help you?

Support PyLucid to keep it free & growing

Support