# Ontario temperature trends, 1995–2024

This real-data example maps annual temperature trends at **398 selected
MERRA-2 grid centres** inside the bundled Ontario geometry. Every selected cell
has 360 valid monthly records and 30 complete annual means.

![Ontario temperature trends at selected grid centres](regional-trend.svg)

## Results and interpretation

The per-cell OLS slopes range from **-0.299 to 0.856 °C per
decade**. This is a range across selected cells, not an Ontario-wide warming rate.
Approximate 95% HAC intervals include zero at 336 of the 398 centres;
the remaining 62 exclude zero. These individual intervals are not
adjusted for multiple comparisons and do not establish province-wide significance.

Circle colour shows the estimated slope. Dark outlines indicate approximate
intervals including zero. Grey crosses would indicate unavailable trends; none
occur in this example. Blank map positions are unselected locations, not zero
trends. The legend is symmetric around zero and specific to this run.

## Data and method

- User-selected NASA MERRA-2 M2TMNXSLV v5.12.4 monthly files, variable T2M (kelvin,
  converted to Celsius), January 1995 through December 2024.
- Cell-centre selection using the pinned Ontario GeoJSON; islands and holes are
  retained. The geometry does not imply a separate land mask or area weighting.
- Calendar-day-weighted annual means; all 12 valid months required; no imputation.
- Per-cell OLS slopes with approximate Newey-West HAC / Student-t inference.
- No missing months or missing-value records among the selected centres.

The earlier Toronto example centre (43.5, -79.375) lies outside this boundary
geometry and is excluded. Cell-centre selection and nearest-location extraction
answer different spatial queries. Collection identity is user supplied and is
not independently authenticated by ARCES.

## Provenance and validation

These are the original saved results generated with **ARCES
0.4.0-dev**, preserved unchanged as the example accompanying
v0.4.0. The recorded software version has deliberately not been relabelled.
The release finalizes the same analysis implementation. The original monthly
downloads are no longer present in the current checkout, so this example was not
regenerated from NetCDF during release preparation.

An independent Python OLS calculation from the annual exports reproduces all
398 slopes. During initial validation, three sampled cells matched the
point-mode slopes and intervals. That consistency check does not independently
validate HAC uncertainty. Run the portable export checks without raw data:

```powershell
python .\tools\verify_ontario_example.py
```

## Reproduce from monthly NetCDF files

Download the same product and date range from NASA Earthdata, with spatial
coverage of the entire Ontario boundary. Put only the intended 360 monthly files
in one directory; directory discovery is nonrecursive. Do not mix in extra
manual samples. The raw files are not included in this repository.

```powershell
.\scripts\ontario.ps1 -InputDirectory "C:\path\to\monthly-files"
```

The helper builds/tests Release and creates a new results directory. The bundled
boundary and its checksums are recorded in [boundary.source.json](boundary.source.json).
Results can change with input collection, data revisions, boundary, coverage or
HAC settings. See [regional methods](../../docs/REGIONAL.md).

## Included outputs

- [Offline report](report.html): download this example folder and open locally;
  GitHub displays HTML source.
- [Static SVG map](regional-trend.svg).
- [Per-cell trends and coverage](regional.csv).
- [Annual means](annual.csv) and [coverage gaps](gaps.csv).
- [Selected centres and statistics](cells.geojson).
- [Run metadata](regional.json).
- [Exact selection boundary](boundary.geojson) and [provenance](boundary.source.json).

## Attribution and limits

NASA GMAO & Pawson, S. (2015), MERRA-2 monthly single-level diagnostics v5.12.4,
https://doi.org/10.5067/AP1B0BA5PD2K.

Boundary: geoBoundaries / Statistics Canada; see the included source metadata and
[boundary attribution](../../data/boundaries/README.md). Boundary data retain their
own license terms; the ARCES MIT code license does not replace them.

This is an exploratory, location-specific analysis, not causal attribution,
a forecast, an area-weighted Ontario average, or an interpolated temperature surface.
