1

I have a fairly in depth set of numerical results being displayed in tables and plots using R/shiny and published online through the teams xxx.shinyapps.io website system.

This has worked fantastically well but I have found that the RStudio preview of my ggplot2 plots to be vastly different to the published versions. In particular, given a set width, height and resolution, the axis text, main text and plotting character annotations are much smaller in the preview compared to the published version. This has made it a nightmare to aesthetically hone these plots to what I want. I have played around with renderPlot() and plotMap() settings but to no avail.

I am using R 3.2.3 in RStudio 0.99.879 with shiny 0.13.2 and ggplot 2.1.0. Has anyone encountered something similar in their shiny/ggplot2 travels?

  • Have you seen this? http://stackoverflow.com/questions/17838709/scale-and-size-of-plot-in-rstudio-shiny – Roman Luštrik Apr 06 '16 at 07:17
  • Yes, I saw this but it doesnt describe my situation. My problem is the ggplot2 plot annotation in the preview from RStudio does not match the published version in my chrome browser. – Jaydee Taylor Apr 07 '16 at 05:19
  • Of course it doesn't. That's why I thought you would want to control the width and height of the plot in your application, ignoring what Rstudio shows you. Unfortunately the cycle is far longer than plotting in real time. – Roman Luštrik Apr 07 '16 at 07:14
  • I have pretty much done this but, as you said, the cycle to sort this out is much longer and its completely trial and error. These systems are purpose built to avoid that. – Jaydee Taylor Apr 07 '16 at 12:54
  • Perhaps you could bind width to a variable you can control through a slider or some sort of input window and experiment what works for you. – Roman Luštrik Apr 07 '16 at 13:16

0 Answers0