I am trying to install the StatsBombR package.
However, when I run devtools::install_github("statsbomb/StatsBombR), I get an error saying that lazy loading failed for package StatsBombR. The full error message is as follows:
Warning: replacing previous import ‘foreach::when’ by ‘purrr::when’ when loading ‘StatsBombR’
Warning: replacing previous import ‘jsonlite::flatten’ by ‘purrr::flatten’ when loading ‘StatsBombR’
Warning: replacing previous import ‘foreach::accumulate’ by ‘purrr::accumulate’ when loading ‘StatsBombR’
Error in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) :there is no package called ‘SDMTools’Calls: ... loadNamespace -> withRestarts -> withOneRestart -> doWithOneRestart
Execution halted
ERROR: lazy loading failed for package ‘StatsBombR’
How can I fix this issue and install the StatsBombR package?