German Umlaut characters in R markdown

后端 未结 2 2051
旧时难觅i
旧时难觅i 2021-01-07 23:25

How can I display non-English characters in R-markdown? In an otherwise English document, I would like to render a single \'u\' with two dots (an \'umlaut\') on top

2条回答
  •  长情又很酷
    2021-01-08 00:15

    You can use standard HTML code for this. For example, the German letter ä can be displayed by placing the corresponding vowel after an ampersand sign, followed by uml;, i.e., ä.

    Here's an example of a .Rmd file:

    ---
    title: "Umlauts with Rmarkdown"
    output: html_document
    ---
    
    ## This is a sentence with many umlaut characters:
    
    Herr Müller sagt: "Über den Wolken können Sonnenuntergänge 
    besonders schön sein."
    

提交回复
热议问题