Repository navigation
Expand file tree
/
Copy pathMLproject
More file actions
86 lines (81 loc) · 3.56 KB
/
Copy pathMLproject
File metadata and controls
86 lines (81 loc) · 3.56 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
name: ewars_plus_template
target: disease_cases
required_covariates:
- population
supported_period_type: any
allow_free_additional_continuous_covariates: true
user_options:
candidate_lags:
type: array
items:
type: integer
default: [7, 10, 12]
description: Candidate lags considered during per-(location, covariate) lag selection. For each (location, covariate), the lag with the highest mean expanding-window CV log-score is selected (ties broken to the smallest lag). Set n_lags to bypass selection.
lag_selection_cv_folds:
type: integer
default: 3
description: Number of expanding-window CV folds used during lag selection.
n_lags:
type: array
items:
type: integer
default: []
description: Manual override. If set, lag selection is skipped and these lags are used directly (one value per covariate, or a single value applied to all).
precision:
type: number
default: 0.01
description: Prior precision on fixed effects.
region_seasonal:
type: boolean
default: false
description: Optional region-specific seasonal effect.
location_specific_effects:
type: boolean
default: false
description: If true, add a per-location RW1 deviation (replicate=ID_spat) on inla.group(<cov>_lag) for each covariate, in addition to the shared global smooth — hierarchical "global curve + per-location deviation" with partial pooling.
lag_grouping:
type: string
default: location
description: Level at which lags are selected. "location" (default) selects one lag per (location, covariate). "parent" selects once per parent org unit (the `parent` property of the dataset's geojson features) on the population-weighted aggregate of its locations, then shares that lag with every location in the group — far fewer CV fits, and useful shrinkage when per-location counts are sparse. Falls back to "location" with a warning if the data carries no usable parent ids.
nonlinearity:
type: string
default: rw1_inla_group
description: Which backend to use for the lagged-covariate effect. "rw1_inla_group" (default) — RW1 smooth on the inla.group()'d shifted column (matches ewars_Plus's selected_Model_form_rw). "linear" — plain linear term in the shifted column. New backends can be registered in lib.R without touching predict.R.
meta_data:
display_name: CHAP-EWARS-Plus Model
description: >
Bayesian hierarchical INLA model for case counts with adaptive
per-district selection of climate-covariate lags. A clean
re-implementation of the central ideas in the ewars_Plus model.
author: CHAP team
author_assessed_status: orange
organization: HISP Centre, University of Oslo
organization_logo_url: https://landportal.org/sites/default/files/2024-03/university_of_oslo_logo.png
contact_email: knut.rand@dhis2.org
citation_info: >
Climate Health Analytics Platform. 2026. "CHAP-EWARS-Plus model".
HISP Centre, University of Oslo.
adapters: {'Cases': 'disease_cases',
'E': 'population',
'month': 'month',
'week': 'week',
'ID_year': 'year',
'ID_spat': 'location',
}
docker_env:
image: ghcr.io/dhis2-chap/docker_r_inla:master
entry_points:
train:
parameters:
train_data: path
model: str
model_config: path
command: "Rscript train.R {train_data} {model} {model_config}"
predict:
parameters:
historic_data: path
future_data: path
model: str
out_file: path
model_config: path
command: "Rscript predict.R {model} {historic_data} {future_data} {out_file} {model_config}"