Pause: Pause

Description Usage Arguments Details Value Author(s) See Also Examples

Description

This function prompts for return key and waits until the return is pushed to continue execution. It is used often to view plots coded in a loop one at a time allowing the user to control when the next plot should be displayed

Usage

1
Pause(str = "continue", quiet = FALSE)

Arguments

str

optional string to display. Defaults to "continue".

quiet

if TRUE, no prompt is displayed. Default is FALSE

Details

The Pause function uses readline to wait until a newline character (produced by the Enter key) is given. Instead of pressing Enter, a newline character can be used to automate this waiting time.

Value

NULL is returned by invisible

Author(s)

Stefan Avey

See Also

readline, invisible

Examples

1
2
3
4
for(p in 1:10) {
  plot(-10:10, (-10:10)^p, type='b')
  Pause(paste0('see plot of x^',p+1))
}

stefanavey/aveytoolkit documentation built on March 5, 2020, 12:49 a.m.