hotPaths {proftools} | R Documentation |
Hot Paths in Profile Data
Description
Computes and displays hot paths in profiling data.
Usage
hotPaths(pd, value = c("pct", "time", "hits"), self = TRUE,
srclines = TRUE, GC = FALSE, memory = FALSE, maxdepth = 10,
self.pct = 0, total.pct = 0, short = ". ", nlines = NA)
Arguments
pd |
profile data as returned by |
value |
character; show result as percentage, time, or hits. |
self |
logical; include self time for each stack in the result. |
srclines |
logical; include source information, if available, or not. |
GC |
logical; include GC information or not. |
memory |
logical; include memory use information or not. |
maxdepth |
integer; stacks are truncated to have at most
|
self.pct |
numeric; stacks with self percent values below this level are dropped. |
total.pct |
numeric; stacks with total percent values below this level are dropped. |
short |
character; abbreviation to be used for functions lower on the stack. |
nlines |
integer; number of lines to show. The lines shown are the ones with the highest total percentage. |
Details
The hot path ordering sorts stacks in the profile data first by the
frequency with which the bottom functions on the stack are called, with
highest frequency first, then within each bottom function by the
frequency of the bottom two, and so on. Examining the result of
hotPaths
starting with low values of maxdepth
and then
moving to higher levels is a useful way to expore where the
computational effort is concentrated.
Value
A data frame designed to produce a useful printed result.
Author(s)
Luke Tierney
See Also
Rprof
,
summaryRprof
,
flatProfile
,
filterProfileData
,
readProfileData
,
plotProfileCallGraph
,
profileCallGraph2Dot
Examples
pd <- readProfileData(system.file("samples", "glmEx.out", package="proftools"))
hotPaths(pd)
hotPaths(pd, maxdepth = 8)