Hello Everyone, I am having some trouble with R Studio and installing the packages I need. I had these installed not even one month ago so I'm not sure why they're not available now. I have tried, for example installing the markovchain package and these are the error messages I get: > install.packages("markovchain") WARNING: Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding: https://cran.rstudio.com/bin/windows/Rtools/ Installing package into ‘C:/Users/AlexandraBirkett/AppData/Local/R/win-library/4.2’ (as ‘lib’ is unspecified) trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.2/markovchain_0.9.1.zip' Content type 'application/zip' length 1894237 bytes (1.8 MB) downloaded 1.8 MB package ‘markovchain’ successfully unpacked and MD5 sums checked The downloaded binary packages are in C:\Users\AlexandraBirkett\AppData\Local\Temp\Rtmp8Qu79v\downloaded_packages > library(markovchain) Package: markovchain Version: 0.9.1 Date: 2023-01-20 BugReport: https://github.com/spedygiorgio/markovchain/issues Warning message: package ‘markovchain’ was built under R version 4.2.3 I have tried uninstalling and reinstalling R studio, updating R studio and also downloading 'R Tools' as mentioned in the error message. As another example, when I try to install the glmnet package, this is the error message I receive: > install.packages("glmnet") WARNING: Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding: https://cran.rstudio.com/bin/windows/Rtools/ Installing package into ‘C:/Users/AlexandraBirkett/AppData/Local/R/win-library/4.2’ (as ‘lib’ is unspecified) trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.2/glmnet_4.1-7.zip' Content type 'application/zip' length 2446887 bytes (2.3 MB) downloaded 2.3 MB package ‘glmnet’ successfully unpacked and MD5 sums checked The downloaded binary packages are in C:\Users\AlexandraBirkett\AppData\Local\Temp\RtmpKYCK0S\downloaded_packages I'd really appreciate some help from somebody so I can continue with my Paper B prep for Wednesday. Alex
Hi Alex Although you're getting warning messages, it does seem to say that the packages were installed. What happens if you run: library(markovchain) and try to use the functionality? All the best Andy
Hi, I am facing the same issue with being unable to download the markov chain package. Error in library(markovchain) : there is no package called ‘markovchain’ Could anyone please assist. Thanks.
Hello If you run the library command and it can't find the package, then it hasn't been installed. What happens when you try to run: install.packages("markovchain") Andy