Save at the right dimensions at 300 dpi
ggsave_facebook(
filename,
plot = ggplot2::last_plot(),
device = NULL,
path = NULL,
scale = 3,
width = 1200,
height = 630,
units = "px",
dpi = 300,
limitsize = FALSE,
bg = "white",
...
)
File name to create on disk.
Plot to save, defaults to last plot displayed.
Device to use. Can either be a device function
(e.g. png), or one of "eps", "ps", "tex" (pictex),
"pdf", "jpeg", "tiff", "png", "bmp", "svg" or "wmf" (windows only). If
NULL
(default), the device is guessed based on the filename
extension.
Path of the directory to save plot to: path
and filename
are combined to create the fully qualified file name. Defaults to the
working directory.
Multiplicative scaling factor.
Plot size in units expressed by the units
argument.
If not supplied, uses the size of the current graphics device.
One of the following units in which the width
and height
arguments are expressed: "in"
, "cm"
, "mm"
or "px"
.
Plot resolution. Also accepts a string input: "retina" (320), "print" (300), or "screen" (72). Applies only to raster output types.
When TRUE
(the default), ggsave()
will not
save images larger than 50x50 inches, to prevent the common error of
specifying dimensions in pixels.
Background colour. If NULL
, uses the plot.background
fill value
from the plot theme.
Other arguments passed on to the graphics device function,
as specified by device
.
filename, quietly