Importing R Code in Knime

Hi Team,

I have build a code in R for scraping a webpage in R, the results from the scraping of webpage is saved as a dataframe in R. Now i want to import the complete code of R in knime and make that execute from knime.

Further from that code i want to build a word cloud in knime.

Am not being able to get the complete R code in knime. please help me how it can be done.

thanks in advance.

Regards
AJ

Hi Team,

on top of my above question, possibly my R nodes are also not working, alhough i have installed both the Rserve and Cairo Packages in R.

then i tried to knime path to R home, where i am receiving this error. (Snapshot attached)

Location of my R packages is : C:\Users\user\Documents\R\win-library\3.5, could it be because of system having another version : where it is installing packages.

Thanks in advance.

Regards
AJ

There are two basic possibilities to use R with KNIME

  • you have a R version on your computer and you point KNIME to it (“KNIME Interactive R Statistics Integration”)
  • KNIME provides you with an ‘integrated’ R package that sits somewhere deep in the KNIME folders (“KNIME R Statistics Integration (Windows Binaries)”)

I would advise to use the first option. So first to proper install R (and maybe RStudio to have an easier handling) and then point KNIME to it. There are further R integrations but they may be confusing but they can coexist.

You would have to make sure KNIME recognises the R version when you press apply in the settings. Not red text or warnings. The screenshot is from a Mac but Windows should behave in the same way.

The path in your first screenshot is not the path that is shown in the second one. And I think KNIME wants full blown windows paths - with c:\program files…

1 Like

Greetings,

Thanks form the reply,

Yesterday only, i kind of installed most the R extensions in knime and rebooyted multiple times which eventually lead knime to pick up the R path to home by itself. BUt i didnt knew due to which extension it has happened.

Many Thanks for your response and help.

But now am facing the issue, when running to install rvest package in knime, it gives an error “unable to move temporary installation ‘C:\Program Files\KNIME\plugins\org.knime.ext.r3.bin.win32.x86_3.4.2.v201712011139\R-Inst\library\file243432a44570\mime’ to ‘C:\Program Files\KNIME\plugins\org.knime.ext.r3.bin.win32.x86_3.4.2.v201712011139\R-Inst\library\mime’ in knime”.

Steps am trying to resolve it:

  1. disable my antivirus.
  2. Restarting knime as administrator.

Request your help on the same.

Many thanks in advance…

Thanks and Regards
AJ

I would recommend to install RStudio (https://www.rstudio.com/products/rstudio/download/) which features a comfortable method to install new packages. Installing R packages from within KNIME is possible, I have a workflow for that somewhere I can look up later.

I would recommend to have R and RStudio as stand alone programs besides KNIME so you could also test R code, install and update packages.

From your folder it seems you are using the built in R version provided by knime. I would recommend reinstalling that extension from knime and use a standalone R installation.

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