Skip to content

Instantly share code, notes, and snippets.

@jakosz
Created February 11, 2014 12:46
Show Gist options
  • Save jakosz/8934230 to your computer and use it in GitHub Desktop.
Save jakosz/8934230 to your computer and use it in GitHub Desktop.
# Fire all three functions on an igraph object and get the execution times:
test_times <-
function(g, width, height) {
return(list(
tig = system.time(plot_igraph(g, file = 'igraph.png', width = width, height = height)),
tse = system.time(png_segments(g, file = 'segments.png', width = width, height = height)),
tmc = system.time(plot_segments_mc(g, file = 'segments_mc.png', width = width, height = height)),
imt = as.numeric(.imTime)
))
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment