I have just downloaded r and I am trying to download quantstrat. The only problem is that when I run the following code:
install.packages("devtools")
require(devtools)
install_github("braverock/blotter")
install_github("braverock/quantstrat")
I obtain the this message error:
Error: Failed to install 'blotter' from GitHub:
System command 'R' failed, exit status: 134, stdout + stderr (last 10 lines):
E> dyld: lazy symbol binding failed: Symbol not found: _utimensat
E> Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libR.dylib (which was built for Mac OS X 10.13)
E> Expected in: /usr/lib/libSystem.B.dylib
E>
E> dyld: Symbol not found: _utimensat
E> Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libR.dylib (which was built for Mac OS X 10.13)
E> Expected in: /usr/lib/libSystem.B.dylib
E>
E> /Library/Frameworks/R.framework/Resources/bin/build: line 10: 869 Done echo 'tools:::.build_packages()'
E> 870 Abort trap: 6 | R_DEFAULT_PACKAGES= LC_COLLATE=C "${R_HOME}/bin/R" --no-restore --no-echo --args ${args}
My solution was to install R 3.5 on top of R 4.02. Then I selected 3.5 by holding ctrl when opening Rstudio. It took a considerable time to create the build and update Rtools to version 3.5. But eventually I got it working and was able to run the code without problems...... assuming of course that you ran into problems with the Datacamp course as well.
See here: https://support.rstudio.com/hc/en-us/articles/200486138-Changing-R-versions-for-RStudio-desktop ... quantstrat working