0

I have this rmarkdown file:

---
title: "Hi"
author: "me"
date: 'July 2023'
output:
  slidy_presentation: default
  powerpoint_presentation: default
---


## R Markdown


This is an R Markdown presentation. Markdown is a simple formatting syntax for authoring HTML, PDF, and MS Word documents. For more details on using R Markdown see <http://rmarkdown.rstudio.com>.

When you click the **Knit** button a document will be generated that includes both content as well as the output of any embedded R code chunks within the document.

For a slidy presentation (html),I want to introduce, for example, this logo https://w7.pngwing.com/pngs/574/475/png-transparent-logo-xunit-random-org-randomness-computer-software-logo-github-blue-angle-text.png into the bottom center of the first slide and in the top right of the rest of the slides. Additionaly, I want to add a last slide with the logo in the center of the page.

Amc
  • 131
  • 8

1 Answers1

0

I think you could use Latex to solve the problem. Below is an example from my rmd file for you reference.

documentclass: ctexart
fontsize: 11pt
geometry: margin=2cm
pagesize: A4paper
output:
  rticles::ctex:
    fig_caption: yes
    number_sections: yes
    toc: no
mainfont: 更纱黑体 UI SC #LiberationSerif
sansfont: 更纱黑体 UI SC Xlight #LiberationSans
monofont: 等距更纱黑体 SC Light #LiberationMono
header-includes:
    - \usepackage{fancyhdr}  #Load fancyhdr package for head and foot
    - \usepackage{xeCJK}
---
\pagestyle{fancyplain} 
\fancyhead[L]{\includegraphics[height=1.2cm]{cdmlogo.png}} #Print the logo top left
\fancyhead[R]{打印日期\today}