On 09/07/2018 6:18 AM, Steven Yen wrote:
I have had trouble installing packages (e.g., car, aod) in some computers (such as computers in the student lab) but no problem in my own laptop. Installation typically goes through, but after I got out and back in R (and RStudios), the error message says "packages xxx not available". That is, earlier installation of the packages did not stay (despite the successful installation message). I went back as far as R3.0.3 and there is no problem. Does this tell anyone what may be going on? Thanks.
The most common package installation problem in Windows is using different permissions to install R and the packages. Typically R is installed as administrator, but the packages are not. This means the packages can't be installed to the system library, so they get installed in a user's personal library, and the user probably may need to set .libPaths() explicitly to see them.
To check for this, print .libPaths() just after installing the packages, and again when starting a new session. If the printed list of paths is different, you'll have problems.
Duncan Murdoch ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.