I'm trying to use a non squared image in a {ggimage} layer but I can't seem to make the ratio fit the orignal image ratio. Documentation points to the asp argument but this doesn't seem to work.
Here's an obviously non square image :…
I would like to use vector graphics stored in external files (e.g. SVG) as my plotting symbols in a ggplot2 figure. e.g. following this example from the grImport vignette (Fig. 8) https://cran.r-project.org/web/packages/grImport/vignettes/import.pdf…
I would like to use custom symbols and annotation on a geom_sf polygon layer that is placed on a google basemap. Initially, I had difficulty with the basemap and polygon lining up correctly
So I used this Stack Overflow solution to fix it. Now the…
When researching this answer, I tried to draw the image strip via geom_image() from the ggimage package but couldn't get it to work. geom_image() modifies the images aspect ratios, and I don't know how to prevent it from doing it (or whether that…
I would like to map OHS incidents over a PNG of a hospital floorplan using ggplot2. I have tried reading this non-geographic map in as a ggimage.
So far I have tried the following with the dataset (14462) observations that I have.
Example…
The following graph can be produced from the R code given below. The images used in the graph are fetched from website. I'm wondering how to use images from computer.
library("ggplot2")
library("ggimage")
set.seed(2017-02-21)
d <- data.frame(x =…
I'm having trouble figuring out how to highlight multiple colors with ggimage.
It's clear how one can set different images to a single color (from vignette):
library("ggplot2")
library("ggimage")
set.seed(2017-02-21)
d <- data.frame(x =…
This question is related to Can geom_image() from the ggimage package be made to preserve the image aspect ratio? but in my application I want to make a scatterplot, using images scaled in proportion to their actual image sizes.
The figure (done…
History: Extracted raster data from the static Google map png, loaded it on the R device through ggimage.
library (png)
library (ggmap)
rasterArray <- readPNG ("My.png")
x = c (40.702147,40.718217,40.711614)
y = c…
I am trying to use images (e.g. country flags) in a ggraph network. I was looking to use ggimage's geom_image, however I reckon that the function needs to be adapted to work with ggraph where we do not specify the x and y…
I am trying to create an infographic style plot in ggplot but am having a lot of trouble figuring out how to start. I want to plot counts of a variable (women) inside of an image, with the name of the country underneath. I figured this would need to…
I wanted to add an image extracted from a webpage (LeBron_James assigned below) to the ggplot using ggimage package. How can i add it to the ggplot rscript below?
GGplot_mean_performance <- FirstPick_Wage_Performance %>%
ggplot(aes(x=Player,…
I am plotting a scatterplot in ggplot with icons and I am stuck with producing a legend using the icons.
THere is a function in the ggimage documentation called "draw_key_image" but I don't really understand how to use it or the required arguments.…
I'm trying to insert hockey pucks into my ggplot. On font awesome, I found a hockey puck icon. I was hoping that ggimage::geom_icon could import font awesome icons, but unfortunately it doesn't:
library(ggimage)
set.seed(2017-02-21)
d <-…