Questions tagged [opencpu]

OpenCPU is a software framework for embedded statistical computation and reproducible research. The server exposes a web API interfacing R, Latex and Pandoc.

OpenCPU provides a REST API to the R computing language. One of the goals is to be able to embed R functionality in scalable systems and web applications, without requiring the user or system to install R.

OpenCPU deals with some of the technicalities that come with R and statistical computing, so that you can focus on your application. Furthermore, OpenCPU implements the concept of Open Computing. In a nutshell this comes down to the following:

Any client can execute arbitrary R code on an OpenCPU server. All R code on the server is by definition Open Source, and readable by anyone. When you publish your own code on the server, it authomatically becomes Open Source. A helpful UNIX analogy is that you have at least r-x privileges on anything on the system, and you rwx in your home directory.

We can mention the two sides of opencpu:

  • On the server side, opencpu serves R packages
  • On the front end side, opencpu is also a js library to interact with the REST API
268 questions
0
votes
3 answers

php guzzle OpenCPU POST request for a simple R package function stucks during execution

The php guzzle OpenCPU POST request for the simple R DemoPackage function $response = $client->request('POST','http://178.254.13.220/ocpu/library/DemoPackage/R/addition/json', ['json' => $jsontext, 'debug' => true]); stucks during execution on a…
0
votes
1 answer

How to CURL in PHP as expected by openCPU file passing

I am trying to generate a datatable on my HTML using ajax which calls a php to obtain JSON. HTML
user2359902
  • 121
  • 1
  • 7
0
votes
1 answer

How to change the favicon of an OpenCPU application?

I would like to add a custom favicon to my OpenCPU app. Although I manually set the favicon to be a custom image, it gets override by the default cloud icon from OpenCPU.
zolastro
  • 918
  • 12
  • 29
0
votes
0 answers

Opencpu POST request times out in 90 seconds

POST request to an OpenCPU function times out at 90 seconds. response <- httr::POST(url, httr::config(timeout = 300, verbose = TRUE), httr::content_type("application/x-www-form-urlencoded"), body = list(myjson = jsoninput), encode = "form") Error:…
rg18
  • 1
  • 2
0
votes
1 answer

Cleaning the tmp files from opencpu server immediately

I have build a app with some opencpu CORS requests with datasets from the app database. This are sensitive datasets. Unfortunately you can access these datasets after request with die /tmp/{session_id} Now i want to delete the session files, in best…
M.o.
  • 11
  • 4
0
votes
1 answer

Cannot see all my functions when running Open CPU single-user server

When I run ocpu_start_app("my_package") not all the functions are displayed and I cannot access those that are not listed, although they are under the my_package/R/ folder as the OpenCPU documentation states.
zolastro
  • 918
  • 12
  • 29
0
votes
1 answer

display a visNetwork object with opencpu

I'm trying to embed a visNetwork object returned from a function, into an html div but so far I have no success. Let's say that there is an R function that returns a visNetwork object. In its simplest form could look like: get_plot <-function() { …
J. Doe
  • 619
  • 4
  • 16
0
votes
1 answer

OpenCPU with R 3.5.1

Since yesterday everything was all right because I used openCPU with R 3.4.4 . Today I tried to install in a fresh ubuntu 16.04 system the R 3.5.1 because I had a problem with a package. So what I did is following: # Repos for R3.5.1 sudo…
J. Doe
  • 619
  • 4
  • 16
0
votes
1 answer

Installing openCPU with exotic path to Apache

I am installing OpenCPU on a production RedHat 7 Server and it turned out that the path to their Apache server is not /etc/httpd but something else. Apparently, OpenCPU was still referring to /etc/httpd and therefore did not work. I am wondering…
0
votes
2 answers

Accessing R objects from subprocess into parent process

In the context of teaching R programming, I am trying to run R scripts completely independently, so that I can compare the objects they have generated. Currently, I do this with R environments: student_env <- new.env() solution_env <-…
filipsch
  • 195
  • 1
  • 10
0
votes
1 answer

Accessing session folder resources in a multi-instance Opencpu

I have an Opencpu server with my package in it. This package contains a function which generates a plot image. When I send a POST request to this function via Opencpu, I get the session id in response which in turns is actually a folder on the…
Harsh Choudhary
  • 475
  • 5
  • 12
0
votes
3 answers

OpenCPU Docker fails to restart after it is stopped once

I installed opencpu Docker image using docker pull opencpu/ubuntu-16.04. The very first time it starts sucessfully. But if I terminate the process and try to start it again using command docker run -it imageID It gets terminated each time. Need…
Vivek
  • 1
  • 2
0
votes
1 answer

Send local image to R function using opencpu

I am trying to use a local .png file as a function argument in this javascript function to pass it to OpenCPU: function processWithR(promObj) { return new Promise((resolve, reject) => { try { var url =…
PhilG
  • 351
  • 1
  • 4
  • 15
0
votes
1 answer

OpenCPU Delete Session

I am creating multiple sessions in OpenCPU that produces some decently sized files (MB range). These files are stored on disk and accumulate over time. The disk on my system runs out after creating too many sessions over a short time. Once the disk…
Alex Ethier
  • 497
  • 2
  • 7
  • 18
0
votes
2 answers

package or namespace load failed for 'SequentialTranches'

I have installed custom package 'SequentialTranches' in my local VM (IP: 192.168.1.215). But this package is not showing in http://192.168.1.215/ocpu/library/base/R/ I use the above URL to connect from my code. When I access the following URL it…
Sijo M Cyril
  • 660
  • 1
  • 8
  • 14