2

Using Mathematica 12.1.0.0 on Mac OS 10.14

Attemping to use my version of R

Tried using:

Needs["RLink`"]
JLink`UninstallJava[]
InstallR["RVersion" -> "3.61", 
 "RHomeLocation" -> 
  "/Users/james2/opt/anaconda3/envs/Rtest/lib/R/library", 
 "NativeLibLocation" -> 
  "/Users/james2/opt/anaconda3/envs/Rtest/lib/R/library/rJava/jri"]

Received error message: Failed to install R. The following error was encountered:crash in low-lever RLink component or in R runtime

Szabolcs
  • 234,956
  • 30
  • 623
  • 1,263
James
  • 21
  • 1
  • It is hard to say without seeing your directory structure, but I would guess that, first, you need "RVersion" -> "3.6.1" (you missed the dot between 6 and 1, which could make it impossible for RLink to parse the version number), and second, you might want to point "RHomeLocation" to just "/Users/james2/opt/anaconda3/envs/Rtest/lib/R", without the last library subfolder. If this doesn't work, it might help to attach the screenshot of your folder structure for R. – Leonid Shifrin Apr 29 '20 at 20:32
  • It might also help to fire R shell for your R distribution, and execute R.home() there - that should give the path to set "RHomeLocation" to. – Leonid Shifrin Apr 29 '20 at 20:32
  • @LeonidShifrin Helpful comments, it seems you know lots about RLink! Are there any good ways of plotting things with R in 12.1? – user5601 Apr 30 '20 at 00:14
  • @user5601 I am the developer of RLink. Re: plotting - not easy in 12.1, but hopefully will improve in 12.2. I talked about this in my talk on the Wolfram University webinar yesterday, the recording of it should soon become available. – Leonid Shifrin Apr 30 '20 at 07:11

0 Answers0