-1

I want to be able to use some of R functions / packages within jupyter notebook on DSX. In that case, I would need a python package called 'rpy2'. When I tried installing 'rpy2' following instructions on the DSX page, it gave me an error that says "it cannot locate the R_HOME". Is there a solution / workaround to this problem? Will appreciate your response!

Here's the error I get: Error message When I installed rpy2 on my PC, I had to create the R_HOME env variable and point it to the folder where R exists. On the DSX, I could get the path for R HOME (as "/usr/lib64/R"), but when i try to use 'setx' on the DSX notebook to set this path, I get the following:setx cannot be used to include R_HOME in path

  • You'd be much better off asking this on a project forum, else reading the docs to see if this is a known issue – stephenfin Nov 02 '17 at 10:34
  • 1
    Well, it is not a known issue. I have done my homework regarding this and I posted it here since DSX points me to post me the question here. If it helps, I can include the set of things that I tried. Do you have a solution? Which project forum are you referring to? – Kedar Kulkarni Nov 02 '17 at 10:38

1 Answers1

2

As of now, Rpy2 is not supported when using Notebook on DSX with Spark service from Bluemix.

It complains about a missing header file, Rdefines.h. This can be fixed but Rpy2 expects R to be built as shared libraries, which isn't the case on DSX because Notebook in DSX make use SparkR and doesn't built R as shared library.

http://rpy2.readthedocs.io/en/version_2.7.x/overview.html#requirements

Thanks, Charles.

charles gomes
  • 2,145
  • 10
  • 15