stacktext <- function(x = 0.7, y = 0.1, z = 0.07,
a = NULL, b = NULL, c = NULL, d = NULL, e = NULL, f = NULL, g = NULL,
cex = 1.1, col = "firebrick3", ppos = 3, npos = 1) {
if (y > 0) {
text(x, y, a, col = col, pos = ppos, cex = cex)
text(x, y + z, b, col = col, pos = ppos, cex = cex)
text(x, y + z*2, c, col = col, pos = ppos, cex = cex)
text(x, y + z*3, d, col = col, pos = ppos, cex = cex)
text(x, y + z*4, e, col = col, pos = ppos, cex = cex)
text(x, y + z*5, f, col = col, pos = ppos, cex = cex)
text(x, y + z*6, g, col = col, pos = ppos, cex = cex)
} else {
text(x, y, a, col = col, pos = npos, cex = cex)
text(x, y - z, b, col = col, pos = npos, cex = cex)
text(x, y - z*2, c, col = col, pos = npos, cex = cex)
text(x, y - z*3, d, col = col, pos = npos, cex = cex)
text(x, y - z*4, e, col = col, pos = npos, cex = cex)
text(x, y - z*5, f, col = col, pos = npos, cex = cex)
text(x, y - z*6, g, col = col, pos = npos, cex = cex)
}
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.