View source: R/rstudio-toggle_subsections.R
findFunctionCode | R Documentation |
Find rows which, taken together, are a function
findFunctionCode(documentText, row)
documentText |
|
row |
documentText <- c( "fun1<- function(", "a,", "b = 1) {a^2}", "# blabla", "fun2 <- function(", "a,", "b = 1,", "d = c(a,", "b)) { a + b }", "1+2", "fun3 = function(", "a,", "b = 1) {a^2}", "# blabla" ) row <- 12 lapply(1:length(documentText), function(i) findFunctionCode(documentText, i))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.