Description of issue -
I am trying to install packages on RStudio with the following command
install.packages("caret")
and getting the below error
Error in install.packages : STRING_ELT() can only be applied to a 'character vector', not a 'NULL' Steps taken so far -
Earlier i have checked the paths through .libPaths(), it was showing me 2 paths.
I have changed the RProfile to get in the sync with single path and now when i am running RStudio as administrator its showing me one path.
"C:/Program Files/R/R-3.4.1/library"
But still i am not able to install packages on RStudio
That is weird, it seems your R installation is in a bad state or it has get corrupted some how, try restarting your session, if the problem persists try reinstalling R (remove the old package library before reinstalling).
I meant a fresh R installation, not RStudio installation, RStudio is an IDE for the R programming language but it has no effect on your R package library.