0

I've used this tutorial to create R project and upload it to my Git repository. Now I want to publish this project on a OpenCPU server. As it's said here, "any R package on Github can be used remotely on OpenCPU through the /ocpu/github/ API."

library(devtools)
install_github("user/repository")

However, RStudio says that R package cannot be found. As far as I understand, in the first step I had to create R Package instead of R project. But if I do so, I don't know how to upload it to Git.

Any step-by-step tutorial would be highly appreciated. Please consider that this is the first time I am realizing this procedure.

Klausos Klausos
  • 15,308
  • 51
  • 135
  • 217
  • It's hard to find the problem without a little more detail. Is the R package in the root of the repo? If not, try install_github("user/repository/subdir"). Can you install other github package? Try eg install_github("hadley/httr"). Is devtools install ok? Is Rtools installed ok? – jeremycg Jun 26 '15 at 12:33
  • @jeremycg: Finally I managed to upload R Package to GitHub. Also I installed the package on OpenCPU without errors. But when I call https://public.opencpu.org/ocpu/github/userName/myRepository/R/function, the Browser says "the Package' myRepository' did not successfully install. Either installation failed or github repository name does not match package name." – Klausos Klausos Jun 26 '15 at 12:38
  • 1
    looking at the tutorial you linked, are you sure you made an [R package](http://r-pkgs.had.co.nz/), and not just a project? If you include a link to the repo it would help – jeremycg Jun 26 '15 at 12:54
  • 1
    Is your github repository public? Because if it is private you need to configure your opencpu server to be able to access it. – Jeroen Ooms Jun 26 '15 at 14:58
  • @KlausosKlausos did you find a solution? – Dinesh May 29 '17 at 19:58

0 Answers0