library(grid)
library(gridSVG)
pdf(file = NULL)
pushViewport(viewport())
grid.rect()
grid.circle()
grid.text("hello, world!")
popViewport()
# All grobs and viewports should now be exported with a class attribute
# holding the value of their R class()
grid.export("test-classes.svg", addClasses = TRUE)
dev.off()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.