R Predictor

I get an error executing a R Predictor node with the following message:

ERROR R Predictor 0:75 Execute failed: R evaluation failed.: "load(“C:/Users/Alfredo/AppData/Local/Temp/knime_Nnet81842/~knime38512434442859775.R”)
sapply(c(“neuralnet”, “stats”, “graphics”, “grDevices”, “utils”, “datasets”, “methods”, “base”), function(packages_to_install) {
for (pkg in packages_to_install) {
if(!(pkg %in% (.packages()))) {
library(pkg, character.only = TRUE)

Pls find attached a simple wf. The weird thing is that using only the R Snippet Node it works! Knime release is 4.0.2.


Nnet.knwf (9.1 KB)

Hi @alfroc -

I think the way you are specifying the library is confusing KNIME somehow. When I use just


without the previous folder assignment or lib.loc argument, it works.

(This assumes you have previously installed the neuralnet package in the R folder that KNIME is pointing to. You may want to double check the R Home specified in File --> Preferences --> KNIME --> R.)


Hi @ScottF,
thanks to your suggestion, it works.

I don’t understand why in this particular case it requires neuralnet package in the R home library. The only ways for make that work before were:

  • all R code in a R Snippet node
  • from inside the R Predictor node (Eval Script)


1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.