Path to R Home does not contain an R Executable

Hi everyone,

I’m looking to use the readr library to enable me to read csv files (for I’m finding the CSV Reader node struggles with a few files I have).

It was recommended that I use readr through this thread:

I’m struggling to get readr to work, however.

I’ve downloaded R3.6.1 to my PC, and I’ve downloaded the appropriate libraries, but when I now try to point R Home to where R is stored (as opposed to the KNIME default) I get told the folder does not contain an R Executable.

I’m trying to point R Home to: C:\Program Files\R\R-3.6.1

The only executable file is in C:\Program Files\R\R-3.6.1\bin but then I get the warning: Path to R Home does not contain a folder with name ‘bin’.

It should be noted that when I point KNIME to use its default Path to R Home whilst I can get R to work it will not run the readr library, for the Snippet throws the following errors:
Error: cannot read workspace version 3 written by R 3.6.1; need R 3.5.0 or newer
Error: could not find function “read_delim”

FYI I’m using 32bit Windows 10.

Any help would be much appreciated.

Thanks,

Dom

Hi @dpowyslybbe,

I think reading this post which is provided by @mlauber71 will help you:

:blush:

2 Likes

Thanks for your response @armingrudd ,

On reading those links I believe it could be caused by the fact I don’t have the latest version of the Rserve 'package installed. And the reason I don’t have the latest RServe is because it’s not installing properly with the below errors:

Warning in untar2(tarfile, files, list, exdir, restore_times) :
failed to copy ‘Rserve/src/client’ to ‘Rserve/clients’

  • installing source package ‘Rserve’ …
    ** using staged installation
    Warning in system(“sh ./configure.win”) : ‘sh’ not found
    ERROR: configuration failed for package ‘Rserve’
  • removing ‘C:/Program Files/R/R-3.6.1/library/Rserve’

The downloaded source packages are in
‘C:\Users\master\AppData\Local\Temp\RtmpyQIXw3\downloaded_packages’
Warning message:
In install.packages(“Rserve”, , “http://rforge.net/”, type = “source”) :
installation of package ‘Rserve’ had non-zero exit status

I hope this is because it’s trying to save somewhere within the Program Files folder (which because I’m not an Admin I can’t write to???). Fingers crossed re-installing R outside of the Program Files folder will rectify this.

I’ll report back accordingly.

Many thanks,

Dom

1 Like

R can typically live anywhere on the hard drive and does not need administrative privileges.

Considering installing RServe you might need RTools to compile that. If you have trouble with this and you are not able to use the folder c:\rtools (assuming you are on a windows machine) this entry might be relevant for you:

2 Likes

Many thanks @mlauber71 !

So progress to date is:

  • R is now installed outside of Program Files folder in C:\R_DPL\R-3.6.1
  • Rtools is now installed in C:\Rtools
  • By following your link’s guidance .Renviron is updated to the appropriate path
  • This then enabled me to install Rserve to version 1.8.6
  • I then re-installed KNIME R extensions:
    - KNIME Interactive R Statistics Integration
    - KNIME R Statistics Integration (Windows Binaries)

But when I then try to set Path to R Home to C:\R_DPL\R-3.6.1 I get the original error of “Path to R Home does not contain an R Executable”.

By sticking with the default Path to R Home I then get the below error when trying to use the read_delim function from the “readr” library:
Error: cannot read workspace version 3 written by R 3.6.1; need R 3.5.0 or newer
Error: could not find function “read_delim”

I’m using KNIME 3.7.2 on 32bit Windows 10. Does anyone have any ideas as to what my next steps should be?

Thanks in advance,

Dom

1 Like

I’ve also just installed the Cairo package as another thread suggested this was needed - still no luck sadly as I still get the “Path to R Home does not contain an R Executable” error message

You could try and install a parallel version of KNIME 4.0 to see if that can help. Please be aware there are some major changes in that version including the .table format. So be careful if you save workflows in that version and if you have to share work with people on lower versions.

Also I encountered some strange errors on a Mac with the new version and R, at the moment they seem to be temporary.

Also you should try to set up a completely new workflow to test R at the new location. I have seen strange things where KNIME nodes kept their original settings even if you reset them.

Don’t give up. KNIME and R together can be great.

1 Like

I would uninstall that, because it is another installation that might cause confusion.

Also did you make sure to install the 32Bit version of R?

1 Like

Hi, I’ve uninstalled KNIME R Statistics Integration (Windows Binaries) and I’m definitely on the 32 bit R but still no luck.

I’ve managed to get it to work on a different PC running KNIME 4.0, but I’m wary of upgrading from 3.7.2. I’ll see if there’s anything I’m missing prior to doing that though.

Any further pointers as to where to look would be much appreciated though. Thanks again.

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