Dear R-Help,
<<
# Function to format and cat the date
d <- function() cat(format(Sys.time(), "%m-%d-%Y"))
>>
I want write an email that contains R code and output, as if I
had entered the code at the R prompt. For example:
<<@
f <- function(x) {
x+1
}
f(1)
stem(rnorm(50))
>>
Is there a way to do that without copy and pasting from R?
Also, is there a way to include the date (<<= d() >>) in the
text of my email?
Regards,
useR
<<@ sessionInfo() >>
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.