File: repeat.time.Rd

package info (click to toggle)
r-cran-bit 4.0.4%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 996 kB
  • sloc: ansic: 5,083; makefile: 6
file content (41 lines) | stat: -rw-r--r-- 953 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/timeutil.R
\name{repeat.time}
\alias{repeat.time}
\title{Adaptive timer}
\usage{
repeat.time(expr, gcFirst = TRUE, minSec = 0.5, envir = parent.frame())
}
\arguments{
\item{expr}{Valid expression to be timed.}

\item{gcFirst}{Logical - should a garbage collection be performed
immediately before the timing?  Default is \code{TRUE}.}

\item{minSec}{number of seconds to repeat at least}

\item{envir}{the environment in which to evaluate \code{expr} (by default
the calling frame)}
}
\value{
A object of class \code{"proc_time"}: see \code{\link{proc.time}}
for details.
}
\description{
Repeats timing expr until minSec is reached
}
\examples{

  system.time(1+1)
  repeat.time(1+1)
  system.time(sort(runif(1e6)))
  repeat.time(sort(runif(1e6)))

}
\seealso{
\code{\link{system.time}}
}
\author{
Jens Oehlschlägel <Jens.Oehlschlaegel@truecluster.com>
}
\keyword{utilities}