View source: R/geom-jitter-rast.R
geom_jitter_rast | R Documentation |
geom_jitter
, but creates a raster layerThis geom is similar to geom_jitter
, but creates a raster layer
geom_jitter_rast(
...,
raster.dpi = getOption("ggrastr.default.dpi", 300),
dev = "cairo",
scale = 1
)
... |
Other arguments passed on to |
raster.dpi |
integer Resolution of the rastered image in dots per inch (default=300). |
dev |
string Specifies the device used, which can be one of: |
scale |
numeric Scaling factor to modify the raster object size (default=1). The parameter 'scale=1' results in an object size that is unchanged, 'scale'>1 increase the size, and 'scale'<1 decreases the size. These parameters are passed to 'height' and 'width' of grid::grid.raster(). Please refer to 'rasterise()' and 'grid::grid.raster()' for more details. |
geom_point_rast plot with rasterized layer
geom_point()
understands the following aesthetics (required aesthetics are in bold):
x
y
alpha
colour
fill
group
shape
size
stroke
Learn more about setting these aesthetics in vignette("ggplot2-specs")
.
library(ggplot2)
library(ggrastr)
ggplot(mpg) + geom_jitter_rast(aes(x = factor(cyl), y = hwy), raster.dpi = 600)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.