Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

GUI frontend for R script

We have a set of R scripts, which process some data and produce some results. We want to make these scripts available to basic users, which are not used to commandline of R - we want to provide them some nice GUI, which would allow to:

  • import/export data from MS Excel/Access easily (also supporting Copy/Paste if possible)
  • allow user to change settings/parameters of the process
  • should be running in MS Windows.

Is there any simple, scripting environment which would allow to develop such nice GUI for our R scripts as fast as possible? Need not necessarily be in R language.

like image 269
Tomas Avatar asked Jun 21 '12 18:06

Tomas


People also ask

Can you make a GUI with R?

The R GUI Generator (RGG) framework allows the R user to generate Graphical User Interfaces (GUIs) for R scripts.

Is R Studio a GUI?

R Studio is an integrated development environment(IDE) for R. IDE is a GUI, where you can write your quotes, see the results and also see the variables that are generated during the course of programming.

What is the Rgg program?

RGG is a general GUI framework for R that has the potential to introduce R statistics (R packages, built-in functions and scripts) to users with limited programming skills and helps to bridge the gap between R developers and GUI-dependent users.


1 Answers

There is the RExcel tool that incorporates R as an Excel plugin so the main interface is Excel with R doing the computations in the background. You could set up a sheet so that the user enters their data, then highlights a box and then chooses a menu item or clicks a button and the results are placed in another cell (or set of cells). Note however, that RExcel and the comunication program it user are not free.

Another option is to create your own gui function in R, then have that gui run automatically when you start R (see ?STARTUP) and set this up on the users machine. I have done this for clients before that did not know anything about R, they just double clicked on the icon on the desktop (windows), minimized the main R window when it opened, interacted with the gui that I had programmed to run (I used tcltk, but there are others) and saw the output provided.

You can get data copied from Excel by having the user select the data and click on copy, then in your program run newdata <- read.delim('clipboard') and the data will be in the data frame called 'newdata', you can use write.table(outdata, file='clipboard', delim='\t') to put the data from data frame 'outdata' onto the clipboard and the user can then paste it into Excel (or other programs).

There is also the Rcmdr package which provides a general GUI for R (basic tools) but also has a mechanism where you can create your own menus and dialog boxes for use with the GUI.

like image 67
Greg Snow Avatar answered Sep 29 '22 20:09

Greg Snow