Prints the characters of the input text string one by one, with a specified delay between each character. If the random parameter is set to TRUE, the delay will be a random value between 0.0001 and 0.3 seconds. Otherwise, the delay will be the value specified by the delay parameter.
slow_print(text, random = FALSE, delay = 0.125)
Invisible NULL. The function prints the text to the console.
A string representing the text to be printed. Must be a non-NA string.
A logical value indicating whether the delay between characters should be random. Default is FALSE.
A numeric value representing the fixed delay between characters in seconds. Default is 0.125. Must be a non-negative number.
Satoshi Kume
Slowly Print Text
This function prints the characters of a given text string one by one, with a specified delay between each character. The delay can be either fixed or random.
if (FALSE) {
slow_print("Hello, World!")
slow_print("Hello, World!", random = TRUE)
slow_print("Hello, World!", delay = 0.1)
}
Run the code above in your browser using DataLab