Weather Interactions
Overview
Weather drives both electricity demand (heating/cooling) and renewable supply (wind, solar). The EPF pipeline creates interaction features that capture these relationships more directly than raw weather variables alone.
Raw Weather Inputs
Five population-weighted stations across Spain provide hourly observations via Open-Meteo:
| Variable | Unit | Price Mechanism |
|---|---|---|
| Temperature | °C | Drives heating/cooling demand |
| Wind speed | km/h | Determines wind generation |
| Solar radiation (direct + diffuse) | W/m² | Determines solar generation |
| Cloud cover | % | Reduces solar output |
| Precipitation | mm | Affects hydro availability |
Degree Day Features
Degree days quantify the gap between actual temperature and comfortable baselines:
Heating Degree Days (HDD)
HDD = max(0, 18°C - temperature)When temperature drops below 18°C, each degree below adds one HDD. Higher HDD means more heating demand, pushing prices up. The 18°C threshold represents the point where buildings typically need active heating.
Cooling Degree Days (CDD)
CDD = max(0, temperature - 24°C)When temperature exceeds 24°C, each degree above adds one CDD. Higher CDD means more air conditioning demand, also pushing prices up. The 24°C threshold reflects typical Spanish cooling activation.
Demand-Weather Interactions
Cold × Demand
cold_x_demand = max(0, 15°C - temperature) × demandThis feature captures the intensity of winter heating load. It’s nonzero only when temperature drops below 15°C, and scales with demand level. A cold snap during high-demand hours produces a much larger signal than cold temperatures during low-demand nights.
Temperature Deviation
temp_deviation = temperature - 15°CA signed feature that’s negative during cold periods and positive during warm periods. Unlike HDD/CDD, it provides a continuous signal without thresholds.
Renewable Generation Interactions
Wind × Wind Share
wind_x_wind_share = wind_speed × wind_shareCombines wind speed (supply potential) with wind generation share (system dependence on wind). When wind is both strong and making up a large share of generation, prices drop significantly. This interaction captures the price suppression effect of abundant wind.
Cloud × Solar Share
cloud_x_solar = cloud_cover × solar_shareWhen cloud cover is high and the system depends on solar generation (high solar share), prices are pushed up because solar output is curtailed. During nighttime hours (solar share = 0), cloud cover has no price effect.
GHI × Solar Share
ghi_x_solar_share = ghi_wm2 × solar_shareGlobal Horizontal Irradiance (GHI = direct + diffuse radiation) multiplied by solar generation share. High irradiance combined with high solar share produces cheap electricity. This is the positive counterpart to the cloud-solar interaction.
Precipitation × Hydro
precip_x_hydro = precipitation × (hydro_generation / demand)Rainfall combined with hydro’s share of generation. Sustained precipitation fills reservoirs, enabling more hydro dispatch and lower prices.
Solar-Specific Features
Global Horizontal Irradiance
ghi_wm2 = direct_radiation + diffuse_radiationGHI represents the total solar energy available at ground level. It’s a better predictor of solar generation than either direct or diffuse radiation alone.
Clear Sky Index
clear_sky_index = GHI / theoretical_maximum_GHIRanges from 0 (completely overcast) to ~1.5 (reflection enhancement). The theoretical maximum is computed from solar geometry (elevation angle, day of year). A clear sky index near 1.0 means solar output matches potential; values below 0.5 indicate significant cloud attenuation.
Why Interactions Matter
Raw weather variables alone miss the economic context. Temperature of 5°C means different things at different times:
- 5°C at 3:00 AM: Low demand, minimal heating load → small price impact
- 5°C at 8:00 AM: High demand, morning heating peak → large price increase
- 5°C in August: Unusual, but AC off → moderate price impact
- 5°C in January: Normal, overlaps with peak heating demand → strong price signal
Interaction features encode this context directly, allowing gradient boosting models to capture these relationships with fewer splits.