Reputation: 65
On REHL5.7, after I used install.packages("randomForest")
in R command lines, I get:
installing to randomForest/libs
** R
** data
** inst
** preparing package for lazy loading
** help
*** installing help indices
converting help for package 'randomForest'
finding HTML links ... done
MDSplot html
classCenter html
combine html
getTree html
grow html
importance html
imports85 html
margin html
na.roughfix html
outlier html
partialPlot html
plot.randomForest html
predict.randomForest html
randomForest html
rfImpute html
rfNews html
rfcv html
treesize html
tuneRF html
varImpPlot html
varUsed html
** building package indices
** testing if installed package can be loaded
* DONE (randomForest)
Error in library(randomForest) :
there is no package called 'randomForest'
No error is prompted. Does anyone know how to fix or debug this problem?
Upvotes: 0
Views: 9299
Reputation: 65
Thanks to all comments, I have solved the problem.
It is the lib path problems, the path I am installing to is not in .libPaths().
I solved it by adding the path into .libPaths() by
.libPaths( c(.libPaths(), "/home/admin/user/data"))
and then, my code will find the randomForest package under the added path.
Upvotes: 1