Horizon Chart

Wind Speed Horizon

Meteorological wind speed horizon chart with mint green neon bands showing gusts and calm periods.

Output
Wind Speed Horizon
Python
import matplotlib.pyplot as plt
import numpy as np

COLORS = {
    'bands': ['#0d4d3d', '#1a7a6b', '#27F5B0', '#4ade80'],
    'background': '#0a0a0f',
    'text': '#ffffff',
}

np.random.seed(888)
hours = np.arange(0, 72)  # 3 days
# Wind with gusts
base_wind = 15 + 8 * np.sin(hours * np.pi / 12)
gusts = np.random.exponential(5, len(hours))
wind = base_wind + gusts + np.random.normal(0, 3, len(hours))
wind = np.clip(wind, 0, 50)
wind_norm = wind / 50

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

band = 0.25

ax.fill_between(hours, 0, np.clip(wind_norm, 0, band), color=COLORS['bands'][0])
ax.fill_between(hours, 0, np.clip(wind_norm - band, 0, band), color=COLORS['bands'][1])
ax.fill_between(hours, 0, np.clip(wind_norm - 2*band, 0, band), color=COLORS['bands'][2])
ax.fill_between(hours, 0, np.clip(wind_norm - 3*band, 0, band), color=COLORS['bands'][3])

ax.set_xlim(0, 71)
ax.set_ylim(0, 0.3)

ax.set_title('Wind Speed (km/h)', color=COLORS['text'], fontsize=12, fontweight='bold', pad=10)
ax.set_xlabel('Hours', color=COLORS['text'], fontsize=10)
ax.set_ylabel('Speed (km/h)', color=COLORS['text'], fontsize=10)
ax.set_xticks([0, 24, 48, 72])
ax.set_xticklabels(['Day 1', 'Day 2', 'Day 3', ''])

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

plt.tight_layout()
plt.show()
Library

Matplotlib

Category

Time Series

Did this help you?

Support PyLucid to keep it free & growing

Support