I try to code below to insert and display an image in the presentation file with rmarkdown:
library(imager)
img <- load.image('https://makeshop-multi-images.akamaized.net/figmaster1/shopimages/98/82/1_000000018298.jpg')
plot(img, xaxt = "n", yaxt = "n")
Out:
My question is how could I remove x and y axis from the figure? which means I hope to remove the contents in the grey rectangles.
I've added xaxt = "n", yaxt = "n"
inside plot()
, it seems not working out.
References:
Check the documentation at https://www.rdocumentation.org/packages/imager/versions/0.42.13/topics/plot.cimg