I'm trying to throw a function at purrr::walk2 ie:
library(stats19)
library(purrr)
walk2(.x = 2017, .y = "Accidents", .f = dl_stats19(year = .x, type = .y, data_dir = "./data", file_name = paste0("stats19_", .x, "_", .y), ask = FALSE))
# Error in dl_stats19(year = .x$years, type = types, data_dir = data_dir, : object '.x' not found
I can't figure out why .x isn't being picked up in the function dl_stats19()