Timed | R Documentation |
Timed()
takes two functions as arguments,
namely the function whose time and call frequency
should be measured and a timer object created by newTimer()
.
It returns a timed function.
Timed(FUN, timer)
FUN |
A function whose run time should be measured. |
timer |
A timer generated by |
A timed function.
Other Performance Measurement:
Counted()
,
newCounter()
,
newTimer()
test<-function(seconds) {Sys.sleep(seconds)}
testTimer<-newTimer()
testTimed<-Timed(test, testTimer)
testTimer("Count"); testTimer("TimeUsed")
testTimed(1); testTimed(2)
testTimer("Count")
testTimer("TimeUsed")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.