r-lidar / lidR

Airborne LiDAR data manipulation and visualisation for forestry application
https://CRAN.R-project.org/package=lidR
GNU General Public License v3.0
601 stars 131 forks source link

Problem installing lidR with raster and terra package #524

Closed isabelle3301 closed 2 years ago

isabelle3301 commented 2 years ago

Hi, after installing the lidR package, I keep getting this error when I load the package, and R does not recognise any functions in the package either.

library(lidR) Loading required package: raster Error: package or namespace load failed for ‘raster’ in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]): namespace ‘terra’ 1.4-22 is already loaded, but >= 1.5.12 is required Error: package ‘raster’ could not be loaded

I have tried updating the terra package and reinstalling raster but it still does not work.

I would appreciate any help you could give me.

Jean-Romain commented 2 years ago

You have a problem with raster and/or terra. Not with lidR. Moreover the problem seems explicit

namespace ‘terra’ 1.4-22 is already loaded, but >= 1.5.12 is required

If you have troubles with other packages please ask to the respective developers.

Regards