Found your way home - R default library in windows
Reason about this post
Many R learner (including myself) probably came across the default R library issues in windows system, especially when you are using a company laptop/PC. There are lots of discussion about changing the default directories in R on StackOverFlow and other websites. However, I found using Environment variables seems to be the easiest way to go.
Change the default library via environment variables
Windowskey to trigger the start menu.- Type
Edit system environment variables. - Click the icon shows in the menu.
- Click
Environment variables. - On the bottom half of the dialog, create a new by click
New. - Variable name will be
HOMEif there is noHOMEexisting already. - Variable value will be the desired default directory for R library.
- OK and restart R.
P.S. Admin right will probably be handy for this job.