timePrompt: Time profiling.

Description Usage Examples

View source: R/my_functions.r

Description

Reports time in seconds to the R prompt of the previous command. This function adds a callback which saves the running of individual commands and reports the time in seconds on the next line.

Usage

1

Examples

1
2
3
4
> timePrompt()
0.000s> x <- sample(1:10, size=1e8, replace=T)
1.240s> 
Note - this time is not accurate if child processes or multithreading is involved.  

traversc/trqwe documentation built on Dec. 4, 2020, 4:21 a.m.