0

I'm in rstudio (R version 3.4.4) on windows 10. I'd like to install and load the caret package, but I run into difficulties with package dependencies.

When I try to load caret I get an error message.

I've checked out Caret package not available for version 3.4.2 and Installing the caret package in R.

# Packages  
my_packages = c("tidyverse", "caret", "leaps")


# Installing 
install.packages(my_packages, dependencies = TRUE)


# Loading 
lapply(my_packages, library, character.only = TRUE) 


# Error 
Error: package or namespace load failed for ‘caret’ in loadNamespace(j <- I[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]):
there is no package called ‘recipes’ 

I thought by setting dependencies = TRUE during installation, I'd taken care of any packages needed to load caret. What's going on? Thanks for any help!

StupidWolf
  • 45,075
  • 17
  • 40
  • 72
Robbie
  • 275
  • 4
  • 20
  • 2
    Did you try to load the `recipes` package separately with all dependencies? Additionally it might be time to upgrade to at least >R3.5. Also just as an aside it is good to install RTools to ensure that you have the tools to compile some of the ML packages. – MDEWITT Sep 01 '19 at 12:33
  • Did you try to use the Packages tab within RStudio? That will automatically take care of dependencies. – Monk Sep 01 '19 at 14:06
  • 1
    @MDEWITT, upgrading to the newest version of R (3.6.1) sorted it out! – Robbie Sep 01 '19 at 17:43

0 Answers0