| Algorithm 1 Linear Trend Fitting and Deterministic Residual-Feature Engineering: Pipeline A |
|
Require: Preprocessed, station-grouped dataset ; target y; window sizes ; MI top-K Ensure: Linear model ; residual targets ; selected feature set ; ranked MI scores Rolling Features (station-grouped): For each station s, variable z, and , compute rolling mean and rolling std using Equations (7) and (8) within station s only (rolling and lag features for target-derived variables use strictly past observations only; see Section 3.4) Remove missing values; construct full deterministic feature matrix Fit Linear Trend: OLS regression of y on (training partition only), using Equation (5) Compute Residual: for all t, using Equation (6) MI Scoring: Compute for each feature using Equation (9) Feature Selection: Sort by descending; retain top-K features: return , , |