currently trying to get an output .pdf file for an R assignment, but I keep getting stuck on the following error:
Error in install.packages(update[instlib == l, "Package"], l, repos = repos, :
unable to install packages
Calls: <Anonymous> ... eval -> eval -> update.packages -> install.packages
I uninstalled MikTex, to install TinyTex through R in the markdown file:
```{r data description, include=FALSE}
tinytex::install_tinytex(force=TRUE)
update.packages(ask = FALSE, checkBuilt = TRUE, repos='http://cran.us.r-project.org')
tinytex::tlmgr_update()
options(tinytex.verbose=TRUE)
library(tinytex)
```
for all packages in the document I use the same source (repos='http://cran.us.r-project.org'). Only when I tried to install Tinytex for formatting the .pdf output file did I start to get these errors.
Previous error was:
Error: LaTeX failed to compile APB_EXAM_markdown.tex. See https://yihui.org/tinytex/r/#debugging for debugging tips. See APB_EXAM_markdown.log for more info.
I'm not quite understanding what the problem is: I only have TinyTex installed as above and tried the troubleshooting steps from yihui.org, but still my file fails to give me a .pdf output.
Any help would be very appreciated.