rjupyter-notebookjupyter-irkernel

Cannot get IRkernel::installspec() to work, jupyter-client not visible


I am still in progress to get Jupyter-Notebook and R working together on Windows 10 machine. After solving the problem with install_github() I am now facing just another issue. I am still following the official installation guide, I am stuck at step 2:

Every time I get this error - I have tried this in R GUI and RStudio, the same:

> IRkernel::installspec()
Error in IRkernel::installspec() : 
  jupyter-client has to be installed but “jupyter kernelspec --version” exited with code 127.
In addition: Warning message:
In system2("jupyter", c("kernelspec", "--version"), FALSE, FALSE) :
  '"jupyter"' not found

My attempts so far: It was suggested here and here, that this could be a problem with the PATH variable setting, so I have added Anaconda to the PATH enviroment. I also installed the jupyter-client via the Anaconda console. No change so far. Any ideas?


Solution

  • This answer is based on this by @Ryan, but since the question answered was actually about a Linux based system I put it here in a Windows question:

    One way to overcome the problem - if adding PATH variables to the environment doesn't work - is the following:

    1. If Anaconda is installed and the Jupyter-Notebook with it (should be the standard install), open up the Anaconda prompt, not the Windows command prompt or the Anaconda Navigator
    2. Look up the executable of R (not Rgui or Rstudio), it should be somewhere like C:\Program Files\R\R-3.5.1\bin and copy the path
    3. Paste the path into the Anaconda prompt and start R by typing R
    4. Now execute IRkernel::installspec() once again, this time there shouldn't be an error
    5. Now you can start an R kernel within Jupyter-Notebook