forked from PierreMasselot/RiskExtrapolation
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path12_Parameters.R
More file actions
63 lines (48 loc) · 1.6 KB
/
12_Parameters.R
File metadata and controls
63 lines (48 loc) · 1.6 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
################################################################################
#
# Risk Extrapolation project
#
# Parameters
#
################################################################################
#------------------------
# Parameters
#------------------------
#----- First-stage analysis
# Number of cities in first-stage
nobs <- 60
# Exposure dimension
varfun <- "bs"
varper <- c(10,75,90)
vardegree <- 2
# Lag dimension
maxlag <- 21
lagfun <- "ns"
lagknots <- logknots(maxlag, 3)
#----- Second-stage model
# List of metapredictors in composite indices
metaprednames <- c(Population = "pop", 'Population above 65' = "prop_65p",
'Population density' = "popdens",
'Social isolation' = "isol", GPD = "gdp", 'Unemployment rate' = "unempl",
'Educational level' = "educ", 'Deprivation rate' = "depriv",
'Hospital bed rate' = "bedrates", Imperviousness = "imperv",
'Tree cover density' = "tree", 'Grassland' = "grass",
'Wetness and water' = "water", 'Small woody features' = "woody",
Elevation = "elevation", 'Distance to coast' = "coast_dist", NDVI = "ndvi",
'PM2.5' = "pm25", NO2 = "no2", 'Average temperature' = "tmean",
'Temperature range' = "trange")
# Number of composite vulnerability indices
npc <- 6
# Number of simulations for eCI
nsim <- 1000
#----- Results
# Temperature percentile grid for ERFs
predper <- c(seq(0,1,0.1), 2:98, seq(99,100,0.1))
# Acceptable MMP range
mmprange <- c(25, 99)
# Percentiles to display on x-axis
axisper <- c(1, 25, 50, 75, 99)
# Denominator for death rates
byrate <- 10^5
# Ages to which to display results
agebreaks <- c(45, 65, 75, 85)