Lake Warming Trend & Attribution Skill
Overview
- Trend Analysis: Mann-Kendall test for p-value + year-based Theil-Sen slope
- Driver Attribution: Per-category R² from linear regression, normalized to 100%
Runtime Column Classification
Predictor columns classified by keyword matching on column names:
- Heat: airtemp, shortwave, longwave, radiation, solar, etc.
- Flow: precip, inflow, outflow, discharge, streamflow, etc.
- Wind: wind, gust
- Human: developed, agriculture, urban, impervious, landuse, etc.
Usage
pythonimport sys sys.path.insert(0, '/app/environment/skills/evo-lake-warming/scripts') from utils import run_end_to_end, validate_outputs results = run_end_to_end( data_dir='/root/data', output_dir='/root/output', target_file_keyword='temperature', join_key='Year' ) print(results) validate_outputs('/root/output')
Functions
load_and_merge(data_dir, target_file_keyword, join_key)— load and merge CSVscompute_trend(df, time_col, target_col)— MK p-value + year-based Sen slopeclassify_column(col_name)— keyword-based category assignmentbuild_category_map(predictor_cols)— classify all predictorscompute_attribution(df, target_col, time_col)— per-category R² importancerun_end_to_end(data_dir, output_dir, ...)— full pipelinevalidate_outputs(output_dir)— check output files


