Site icon R-bloggers

The R Shiny packages you need for your web apps!

[This article was first published on Enhance Data Science, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

Shiny is an R Package to deploy web apps using an R backend. Let’s face it, Shiny is awesome! It brings all the power of R to a simple web app with interactivity, user inputs, and interactive visualizations. If you don’t know Shiny yet, you can access a selection of apps on Show me shiny.
As usual with R, the community is great and has created lots of packages for Shiny, here is a personal selection of Shiny packages.
NB: The post focuses on shiny functionalities and visual improvements but it does not deal with data visualization packages. You should check A pick of the best R packages for interactive plot and visualization (1/2) to discover visualizations!

Improving the Shiny UI

This sections will show you some Shiny packages to improve your UI with new components and UI/UX improvements like draggable UI or in-app tutorial.

ShinyDashboard by Rstudio

ShinyDashboard makes it easy to create a dashboard and is based on the AdminLTE Bootstrap theme. Basically, you can build much more complex shiny apps with a sidebar, a header with notifications, messages, … and Bootstrap UI components (box, value box, info box). As it’s based on the adminLTE theme and bootstrap, you can often use their custom HTML classes by adding a few HTML lines to your application.

An example of a Shiny dashboard application

This package should be downloaded with Shiny and is really a must have!

Version: 0.6.1 (June 15, 2017) on CRAN
License: GPL-2
Package components’ License: GPL-2

shiny.semantic by Appsilon

Like ShinyDashboard, shiny.semantic is a wrapper for a web UI: Semantic UI. Semantic UI looks really beautiful and modern and has more varied components and inputs than Bootstrap.

Components from Semantic UI.

Click to view slideshow.

The apps made with this package looks really awesome, you can check this demo app from Appsilon. However, the package is not easy to use at the beginning, its syntax is very close to HTML and may require some adaptation.

Version: 0.1.1 (2017-05-29) on CRAN
License: MIT
Package components’ License: MIT

ShinyBS by ebailey78

ShinyBS adds some Bootstrap components to Shiny such as popovers, tooltips, and modal windows. Since modal windows are now included in Shiny, the main interest of the packages lies in the popover and tooltips. They can be easily added and parametrized using a R syntax.

Version: 0.61 (2015-03-30 ) on CRAN
License: GPL-3
Package components’ License: MIT

shinyjqui by Yang-Tang

Shinyjqui adds the Jquery UI to Shiny and this is really awesome! With the package, you can create drag, resize, sort and animates the elements of your UI with a few lines of code. This really adds a wahoo factor to your apps and corrects the fixed/static aspect of Shiny applications. Just check this example from the repository and you will love this Shiny package!

 

Version: 0.2.0 ( 2017-07-04 ) on CRAN
License: MIT
Package components’ license: CC0

rintrojs by CarlGanz

Is your app really complex? You don’t want your user to get lost and to quit? Then, you should really give a look at rintrojs. It’s a wrapper for the intro.js library to create step-by-step walkthroughs for your app and to show the users how they can use it. You can trigger the intro programmatically (it can be triggered when the user clicks on a ‘Hey I need help’ button) and the intro will highlight the elements of interest in your app with a comment. You can check the demo app to see it working.
This is definitely a must have for complex apps!

Version: 0.2.0 ( 2017-07-04 ) on CRAN
License: GNU Affero General Public License v3.0
Package components’ license (intro.js)
Commercial license for commercial use (price are reasonable though).
GNU AGPLv3 for open-source use.

New Shiny inputs

These Shiny packages bring new inputs and variety to your app.

shinyWidgets by dreamRs

ShinyWidgets brings news and improved inputs from Bootstrap to Shiny:

Examples of inputs from shinyWidgets

You can see a live version of all the inputs here.

Version: 0.3.0 (June 12, 2017) on CRAN
License: GPL-3
Package components’ License: MIT

ShinySky by AnalytixWare

ShinySky also brings some new inputs. Though the package does not seems active anymore, it has some nice inputs that are not in Shiny:

Version: 0.1.2 (2014-3-27) on Github
License: MIT

Make your tables great again

The vanilla tables are so-so, this selection of Shiny packages will help you to create interactive, editable and stylish tables.

DT by RStudio

DT is an interface to the JS library datatables. The package is a must-have if you plan to insert tables in your apps, it improves the vanilla tables with:

Version: 0.2 ( 2016-08-09) on CRAN
License: GPL-3
Package components’ License: Open source components

Formattable by Renkun

Formattable is centered around data presentation and formatting in a table. It has conditional styling options (colors, bar charts, icons, …) for your table and formatting options (Rounding, percentage, …). Even if I tend to prefer DT for its interactivity, I found formattable easier to use for formatting and styling tables.

Example of a formattable (from package repo)

Version: 0.2.0.1 ( 2016-08-05) on CRAN
License: MIT

Rhandsontable by jrowen

Rhansonetable brings handsontable.js into Shiny. Handsontable.js is like excel brought in your internet browser, with rhansontable you can use editable tables in your shiny application!

Example of rhansontable (from the package vignette)

Here is a quick list of its functionalities:

Version: 0.2.0.1 (2016-08-05) on CRAN
License: MIT
Package components’ License: MIT for the community version of handsontable (which is used in the package)

Sparkline by timelyportfolio & ramnathv

Sparklines are tiny plots than can be put in a single cell, they can be used to show trends or evolution over the last periods. Hence, Sparkline is an HTMLWidget to add interactive sparklines in your tables and also includes bar charts and boxplots. That’s a great package to make your tables even more interactive and visually appealing.

Examples of sparkline (from the package repo)

Version: 2.0 ( 2016-11-12) on CRAN
License: MIT
Package components’ License: 3-Clause BSD License ( jquery sparkline)

A text and code editor in your shiny apps: ShinyAce by trestletech

Ace is a web-based code editor and gives you access to syntax coloring and code edition in your web browser. As you have already guessed, ShinyAce is a wrapper for the Ace editor and contains most of its functionalities. The editor field can also be used as an input to run the code from the editor.
[Warning: you should only allow this in restricted/logged parts of your application. You don’t want everyone playing with your server.]

Version: 0.2.1 (2016-03-14) on CRAN
License: MIT
Package components’ License: BSD 3 (Ace)

Interfacing your Shiny app with JS

shinyJs by Dean Attali

ShinyJs greatly improves the interaction between R and Shiny, the package is divided into two parts:

So whether you intend to add more interactivity or to include js code in your application, this package is a must!

Version: 0.9.1(2017-06-29) on CRAN
License: GNU Affero General Public License v3.0 for open-source use

d3R by timelyportfolio

d3R is not really focused on Shiny but on making the use of d3.js easier in R:

d3R removes the painful data transformation part and simplifies the integration of custom d3.js viz’ in R.

Version: 0.9.1(2017-06-29) on CRAN
License: BSD-3
Package components’ License: BSD License (d3.js)

Improving your development pipeline

shinyTest by Rstudio

One of the painful parts of Shiny development is testing of your app.You have to do it manually …hence, the testing is inconsistent and you may forget some cases … and it’s boring and it requires a lot of times.
Shinytest intends to automate applications testing, you need to create your different test once. Each time you want to test the app, shinyTest will run the test and compare the inputs and outputs with the original test. You don’t need to run manual test anymore!

Version: 1.1.0 (2017-06-23) on Github
License: MIT

shinyLoadTest by Rstudio

shinyLoadTest is an extension of shinyTest which will help you to ensure that your applications are scalable. The packages create concurrent sessions which will perform a predefined set of actions to test the ability of your application to sustain the load.

Version: 0.1.0 (2017-06-23) on Github
License: GPL-3

That’s it, our little tour of Shiny packages is done. If you know other packages and wish to share them, please comment, I’d be glad to add them to the post.

You can follow the blog on TwitterFacebook  and subscribe to the newsletter:

EmailThank you for following us!

The post The R Shiny packages you need for your web apps! appeared first on Enhance Data Science.

To leave a comment for the author, please follow the link and comment on their blog: Enhance Data Science.

R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.