library("utilizeR")
context("function.toString")
test_that("function.toString", {
expect_identical(function.toString(function(x) sin(x)), "sin(x)")
expect_identical(function.toString(function(x) {sin(x)}), "sin(x)")
expect_identical(function.toString(function(x) {x<-5*x; sin(x)}), "x <- 5 * x; sin(x)")
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.