After updating Rstudio and R, graphs in Rmarkdown/Rnotebook are getting generated with text that is too small and lines that are too thin. This is true both in the editor and in the generated html files.
This is NOT an issue of the fig.width and fig.height. Changing those increases the overall size of the graph (as usual) but does not effect the size of the text in the graph or the line thickness.
It appears that the graphs are being 'scaled' somehow. Does anyone know how to control this? I've tried setting output.height and output.width but this has no effect.
With which plots this is happening ? Do you use default graphic device ?
There are other option that you can change like dpi or fig.retinaif you want to customize the figure. These two can impact the thin vs thick impression.
Otherwise, I don't really know how to help as I can't reproduce
has restored graphs to something like what I had prior to upgrading.
Something related to scaling must have changed but I can't figure out what. At least my graphs are legible again, but I'd still like to know what changed.
Can some one explain the difference between dpi and fig.retina? Doesfig.retina only effect retina monitors (seems unlikely)? Or is it just an alt way of specifying dpi? Or is is OS-X specific? (I run Rstudio under linux, not OS-X.)
fig.retina : ( 1 ; numeric) This option only applies to HTML output. For Retina displays, setting this option to a ratio (usually 2) will change the chunk option dpi to dpi * fig.retina , and out.width to fig.width * dpi / fig.retina internally. For example, the physical size of an image is doubled, and its display size is halved when fig.retina = 2 .
I believe it will be apply as default is set to 2 in rmarkdown::html_document, but you can change it to 1 if you want to disable it to see the difference.
If you think there is something not right in that, you can open an issue in knitr so that we have insight to possibly revisit or document better the calculations.