How do we plot images at given coordinates in R?
Given 'n' images in a png/jpeg format and 'n' corresponding coordinates in 2 dimensions (x,y): I would like to plot these images at the given coordinates on a single plot. If I find the images to be too big, I would ideally like to plot them as a smaller/scaled version at the given coordinates. How can i achieve such a plot in R? An example of how such a plot would look is given below: xy <- data.frame(x=runif(10, 0, 100), y=runif(10, 0, 100)) require(png) img <- readPNG(system.file("img", "Rlogo.png", package="png")) thumbnails <- function(x, y, images, width = 0.1*diff(range(x)), height = 0