Merging messages

Different messages are placed in separate blocks:

f = function() {
  message('Hello')
  message('World!')
}
f()

Consecutive identical messages are automatically merged into a single block:

f1 = function() {
  for (i in 1:5) message('Hello')
}
f1()
f2 = function() {
  for (i in 1:5) warning('Hello')
}
f2()

A message in message(..., appendLF = FALSE) will be merged with the next adjacent message:

f3 = function() {
  message('Hello ', appendLF = FALSE)
  message('World!')
}
f3()


Try the parsermd package in your browser

Any scripts or data that you put into this service are public.

parsermd documentation built on May 20, 2021, 5:08 p.m.