You can install PhGcode from Github (it will never be placed on CRAN, since it contains experimental code):
install.packages("devtools") devtools::install_github("phgrosjean/R-code")
Look at the Github repository. You can get the csource from there.
To use the package, issue:
library(PhGcode) sessionInfo()
This is a very simple function that takes the cube of its argument:
cube(1:5)
This is a the inverse of cube()
that takes the cubic root of its argument:
cbrt(c(1, 8, 27, 64, 125))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.