We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 606d49e commit 322ad07Copy full SHA for 322ad07
1 file changed
R/distances_for_injury_function.R
@@ -81,7 +81,7 @@ distances_for_injury_function <- function(journeys, dist) {
81
if ('shared_taxi' %in% colnames(distances)) distances$shared_taxi <- distances$shared_taxi * 2
82
83
# multiply auto_rickshaw by 2 to add driver
84
- distances$auto_rickshaw <- distances$auto_rickshaw * 2
+ if ('auto_rickshaw' %in% colnames(distances)) distances$auto_rickshaw <- distances$auto_rickshaw * 2
85
86
## add all car related distances to car distance
87
distances$car <- rowSums(distances[, colnames(distances) %in% c("car", "taxi", "shared_auto", "shared_taxi")])
0 commit comments