binom <- function(p) { plot(0:10, dbinom(0:10, 10, p), ylim=c(0,0.5)) Sys.sleep(0.1) } ignore <- sapply((0:100)/100, binom)