O'Reilly logo

R Data Analysis Cookbook - Second Edition by Kuntal Ganguly

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

How it works...

The Shiny app server code consists of two main parts.

A downloadHandler() function is used to knit the document on demand and passes parameter values to the R markdown document (which is parameterized).

By default,rmarkdown::render() will generate an HTML file that will have all plots and other images embedded directly in the HTML, so you can simply publish or send across the HTML file without any need to handle image files separately. However, you can also generate PDF output using the rmarkdown::render() function just by changing the filename argument of downloadHandler() to "report.pdf". The rmarkdown::render() function has a lot of options to control the processing and output.

More information on this can be found at ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required