可选参数值

函数

say_goodbye <- function(text = "Goodbye!") {
  cat(text, "\n")
}

say_goodbye()
# 输出 "Goodbye!"

say_goodbye("see you")
# 输出 "see you"