Line Break in R Markdown Reports / R Notebooks

Lately I have been struggling to find a way to accomplish a line break in an R Markdown Report / Notebook. It is in fact described in the RStudio documentation, but it is rather difficult to find and not so well explained. This is what they have to say about it:

A backslash followed by a newline is also a hard line break.

Easy to overlook, and perhaps not so pedagogical.

What they mean is this:

\⎵⎵

That is, a backslash ( \ ) followed by two space characters ( ⎵⎵ ).

Enjoy!

VN:F [1.9.22_1171]
Rating: 5.0/5 (2 votes cast)
Line Break in R Markdown Reports / R Notebooks, 5.0 out of 5 based on 2 ratings
Share and Enjoy
  • Facebook
  • Twitter
  • LinkedIn
  • del.icio.us
  • StumbleUpon
  • RSS
  • email
  • PDF

Published by

Samuel

Ph.D. Student in the Department of Computer and Systems Sciences, Stockholm University.

2 thoughts on “Line Break in R Markdown Reports / R Notebooks”

  1. I like to use , because you can add multiple break lines in just one line of code. For example, three breaks would be:

    VA:F [1.9.22_1171]
    Rating: 8.0/10 (1 vote cast)
  2. I like to use “”, because it allows to add multiple breaks in one line of code. For example, three breaks would be: “”

    VA:F [1.9.22_1171]
    Rating: 0.0/10 (0 votes cast)

Leave a Reply

Your email address will not be published.

*