save_code | R Documentation |
Helper function that saves generated R code to a file. Does not overwrite
existing files unless overwrite
is explicitly set to TRUE
.
save_code(code, file, overwrite = FALSE)
code |
character string with R code. |
file |
character string of the filename to be saved. |
overwrite |
whether the existing files should be overwritten. |
## Not run: data <- data.frame(x = rnorm(100), y = rnorm(100)) code <- semproducible(data, formula="y ~ x") save_code(code, "create_data.R") save_code(code, "create_data.R", overwrite = TRUE) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.