基于Web的R语言口译员 [英] web based interpreter for language R
问题描述
我正在寻找语言R的基于Web的口译员. 更精确地说,我正在寻找像 http://codepad.org/这样的IDE,我可以在其中提供代码,服务器应执行并向我提供输出.
我经历了Rapache之类的应用程序,但是由于它们不能接受来自客户端的代码,执行它们并提供结果,因此它们不符合我的要求.
简而言之,我可以找到一个Web应用程序,该应用程序从用户那里获取输入,执行一个特定的R脚本,然后以一种整齐的格式放置输出,而不是一个接受R代码的Web应用程序,执行它,然后将其放置在整洁的方式.
想到了几种可能性:
- ideone 提供了许多不同的语言,其中R是其中一种.运行脚本时,会为您提供一个链接,您可以将该链接嵌入到网页中(不幸的是,该链接未显示输出).如果创建帐户,则还可以存储以前运行的脚本.
- Pro:您可以轻松地在脚本中插入
/plain/
并获得可以直接从R中获取的URL.例如,如果在线脚本的URL为"source("http://ideone.com/plain/PIkeD")直接从ideone服务器中加载脚本. - 缺点:
停留在2.11版可能并不总是R的最新版本.目前是3.2.2版.无法安装其他软件包.输出未显示在提供的嵌入脚本中.
- Pro:您可以轻松地在脚本中插入
-
Cloudstat控制台运行的是最新版本的R(2.15.1)带有许多常用软件包. 使用有一个非常有趣的博客/笔记本界面,该界面集成了代码和输出,但是目前似乎不可用.- Pro:在紧急情况下运行相当简单的操作很有用.
- 缺点:无法安装其他软件包.输出未在代码块中格式化,因此不容易阅读.目前,您无法保存或共享您已运行的代码.
- 优点:R/RStudio几乎可以满足您的所有要求.也允许您使用Sweave和R降价来自动创建文档.这些文件也可以公开托管.在以下示例中,我将页面放置在名为"gallery"的公用文件夹中: http://crunch.kmi.open.ac.uk/people/~mrdwab/gallery/howzat.html
- 缺点:有时加载时间有点慢,但是当我运行RStudio桌面时,我不知道Crunch与运行我自己的RStudio服务器相比如何.
2014年1月10日更新
最近,围绕 R-Fiddle 的讨论也相当活跃共享R代码的方式.看起来,这正是令人敬畏的 http://www.rdocumentation.org/网站的强大力量.>
I am looking for a web based interpreter for the language R. To be more precise , i am looking for a IDE like http://codepad.org/ where i can provide the code and the server should execute and provide me with the output.
I went through applications like Rapache but then they don't fit my requirement as they are not made to accept code from client , execute it and provide the result.
In short , i could find web application which takes input from the user , execute a specific R script and then place the output in a neatly formated way but not a web application which accepts R code ,execute it and then place it in a neat way.
A few possibilities come to mind:
- ideone provides a lot of different languages, of which, R is one of them. When you run a script, you are provided with a link that you can embed in a webpage (but which doesn't show the output, unfortunately). If you create an account, you can also store your previously run scripts.
- Pro: You can easily insert
/plain/
into your script and be able to get a URL that can be sourced directly in R. For example, if the URL for your script online is "http://ideone.com/PIkeD", then you can usesource("http://ideone.com/plain/PIkeD")
to load your script directly from the ideone servers. - Cons:
Stuck at version 2.11Might not always be the most current version of R. Presently at 3.2.2. Can't install other packages. Output doesn't show in the embed script provided.
- Pro: You can easily insert
Cloudstat console runs a more recent version of R (2.15.1) with quite a few commonly used package. It used to have a really interesting blog/notebook interface that integrated code and the output, but that doesn't seem to be available at the moment.- Pro: Useful for running something fairly straightforward in a pinch.
- Cons: Can't install other packages. Output is not formatted in code blocks, so is not easily readable. At the moment, can't save or share the code you've run.
- Pros: Pretty much all you would expect from R/RStudio. Allows you to use Sweave and R markdown to automatically create documents too. These documents can be publicly hosted too. Here's an example where I've placed a page in a public folder called "gallery": http://crunch.kmi.open.ac.uk/people/~mrdwab/gallery/howzat.html
- Cons: Sometimes the loading time is a bit slow, but as I am running RStudio desktop, I don't know how Crunch compares to running my own RStudio server.
Updated January 10, 2014
Recently, there has also been a decent amount of buzz around R-Fiddle as an interesting way to share R code. It looks like it is what powers the awesome http://www.rdocumentation.org/ site.
这篇关于基于Web的R语言口译员的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!