Stream Graph
Gaming Platform Revenue Stream
Stream visualization of gaming revenue across platforms with vibrant neon aesthetics.
Output
Python
import matplotlib.pyplot as plt
import numpy as np
COLORS = {
'background': '#0a0a0f',
'text': '#ffffff',
'grid': '#333333',
}
np.random.seed(404)
years = np.arange(2015, 2025)
n = len(years)
# Gaming platforms
mobile = 20 + 8 * (years - 2015) + np.random.normal(0, 3, n)
console = 40 + 2 * (years - 2015) + 5 * np.sin((years - 2017) * np.pi / 3) + np.random.normal(0, 3, n)
pc = 30 + 3 * (years - 2015) + np.random.normal(0, 2, n)
cloud = 2 + 4 * (years - 2019) * (years > 2019) + np.random.normal(0, 1, n)
vr = 1 + 2 * (years - 2020) * (years > 2020) + np.random.normal(0, 0.5, n)
data = [np.clip(d, 1, None) for d in [mobile, console, pc, cloud, vr]]
platform_colors = ['#6CF527', '#276CF5', '#F5276C', '#27D3F5', '#F5B027']
fig, ax = plt.subplots(figsize=(14, 6), facecolor=COLORS['background'])
ax.set_facecolor(COLORS['background'])
ax.stackplot(years, *data, colors=platform_colors, alpha=0.85, baseline='sym',
labels=['Mobile', 'Console', 'PC', 'Cloud Gaming', 'VR/AR'])
ax.axhline(0, color=COLORS['grid'], linewidth=0.5, alpha=0.5)
ax.set_xlim(2015, 2024)
ax.set_title('Gaming Revenue by Platform (2015-2024)', 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=5)
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
More Stream Graph examples
☕