Book Image

Learning Shiny

By : Hernan Resnizky
Book Image

Learning Shiny

By: Hernan Resnizky

Overview of this book

Table of Contents (19 chapters)
Learning Shiny
Credits
About the Author
Acknowledgements
About the Reviewers
www.PacktPub.com
Preface
Free Chapter
1
Introducing R, RStudio, and Shiny
Index

D3.js integration


This is naturally perfectly possible as D3 visualizations are HTML/JavaScript-based, and as it was already explained in this book, Shiny applications can support this type of content without any problems.

This section will have three main subsections:

  • What is D3.js?

  • networkD3

  • An introduction to htmlwidgets

What is D3?

D3.js is a JavaScript library designed by Mike Bostock. As with any other library in any other language (for example, R), D3 contains a set of functions written in JavaScript that are especially used for visualizations.

The name of this library is an acronym for Data-Driven Documents (three times the letter D) and its name is self-explanatory of the purpose of the library's functions, that is, to produce HTML documents based on data given. Of course, this data can change, and the HTML rendered has to change accordingly.

This kind of process should sound familiar to every reader at this point; graphical objects that change according to the interaction with the end...