2.2 Uninstalling Previous Versions

If you have older versions of either R, or Python, it is recommended to update them to the newest versions in order to avoid any errors. To do this, we firstly need to completely remove the currently installed versions.

Go to Control Panel and select Programs and Features.

Find R and Python versions among your installed software.

2.2.1 Removing RStudio

For a general guide on how to remove RStudio visit the appropriate software website.

Remove RStudio

After uninstalling, your personalized settings are still preserved in a RStudio-Desktop folder. To completely remove any saved settings go to C:\Users\YOUR_PC_USER\AppData\Local, where YOUR_PC_USER is the user that you logged in on your PC.

After removing RStudio, move on to remove R.

2.2.2 Removing R

For a general guide on how to remove R visit the appropriate software website.

Remove R (also remove Rtools if you have it installed)

Uninstalling R only removes files from the initial installation, not packages you have installed or updated. To remove these packages, go to C:\Users\YOUR_PC_USER\Documents\R\win-library, where YOUR_PC_USER is the user that you logged in on your PC.

If you have updated from a previous R version, there is a chance that you will find folder for these earlier versions here as well. Delete the folders corresponding to the version fo R that you no longer have on your PC. If you have uninstalled all versions of R, then delete all of the corresponding folders inside the win-library folder.

2.2.3 Removing Anaconda

Begin by removing the kernelspec of R from JupyterLab. Open cmd as administrator and input jupyter kernelspec list to get a list of kernels:

Then, in order to remove R from JupyterLab input the following command jupyter kernelspec uninstall ir, where ir is the kernelspec of R. If you have more kernels for different versions of R - you should also remove them. Only the python3 kernel should be left.

For a general guide on how to remove Anaconda visit the appropriate software website.