Add spatial autocorrelation statistics (Moran's I, LISA, Geary's C)
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 45/100
Direzione di ricerca
Start by reading hotspots() and emerging_hotspots(), then trace the existing ArrayTypeFunctionMapping backend dispatch pattern for numpy, cupy, and dask variants. Define how global and local statistics, permutation p-values, spatial weights, and categorical join counts fit the raster API; done means the listed statistics support the specified backends and return scalars or grid-matched DataArrays as described.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Motivation
We already have Getis-Ord Gi* via hotspots() and emerging_hotspots(), but Moran's I (global and local/LISA) is the other fundamental spatial statistic that most analysis workflows depend on. Right now users have to leave xarray-spatial to compute these, which breaks the pipeline.
Scope
Statistics:
- Global Moran's I
- Local Moran's I (LISA) with significance testing via random permutation
- Geary's C (global and local)
- Join count statistics for categorical rasters
Spatial weights:
- Queen and rook contiguity derived from the raster grid structure
- Distance-band weights (binary and inverse-distance)
Implementation notes
- Should follow the existing backend dispatch pattern: numpy, cupy, dask+numpy, dask+cupy via
ArrayTypeFunctionMapping. - Local statistics (LISA, local Geary) return xarray DataArrays matching the input grid. Global statistics (Moran's I, Geary's C) return scalar results.
- P-values from permutation testing should be included in the output, either as a second DataArray or as attributes.
- Permutation-based significance is embarrassingly parallel and maps well to both dask chunks and GPU threads.
Related
hotspots()already computes Gi* z-scoresemerging_hotspots()does temporal hot spot classification- PySAL/esda covers this for vector data, but there's nothing raster-native
- Lingua principale
- Python
- Stelle
- 972
- Fork
- 92
- Merge medio
- 2g 12h
- PR unite (30g)
- 7
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di xarray-contrib/xarray-spatial
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 68/100
xarray-contrib/xarray-spatial#3726 ·
-
api area:surface bug severity:medium sweep-api-consistency
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
xarray-contrib/xarray-spatial#3712 ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 88/100
xarray-contrib/xarray-spatial#3710 ·
-
benchmarks: cupy branch in get_xr_dataarray never raises NotImplementedError on non-GPU hosts Apertabug
Difficoltà 1/5 1-3 ore Idoneità per principianti 88/100
xarray-contrib/xarray-spatial#3707 ·
-
area:surface documentation user-guide-example
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
xarray-contrib/xarray-spatial#3464 ·
Tutte le issue di xarray-contrib/xarray-spatial
Issue simili
-
triage/confirmed
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
agentscope-ai/agentscope#2775 ·
-
comp/desktop P3 type/bug
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 92/100
NousResearch/hermes-agent#118866 ·
-
bug
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100
apache/cloudstack#14222 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100