Question: how to install package raster in r?
Answer: To install the raster package you can use install. packages('raster') . When you install the raster package, sp should also install. Also install the rgdal package install.