timeout | R Documentation |
Stop the execution of an expression if the elapsed time exceed a limit
timeout(expr, timeout)
expr |
R expression such as sum(1:5) and muli-line R code inside . |
timeout |
numeric, time limit in second |
return of expr
timeout(
{
for (i in 1:10) {
print(i)
}
},
timeout = 1
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.