Whenever I tried to knit R markdown in beamer presentation format, it keeps on giving me undefined control sequence.
It is fraustrating because it worked fine until yesterday and I have no idea what I changed that causes this error. To show that my code is not the source of the problem, I simply tried to knit an empty page.
code:
---
title: "untitled"
output: beamer_presentation
---
Output:
output file: a.knit.md
! Undefined control sequence.
<argument> ...{subsubsection}\addtobeamertemplate
{theorem begin}{\expandaft...
l.322 }{}
My original file returns the exaclty same error message.
I tried:
- reinstall LaTeX
- reinstall RStudio
- upgrade all packages in R
Any idea how to fix this?
CodePudding user response:
This was just fixed by @UlrikeFischer. @JosephWright is preparing a new beamer release as we speak, it should be available as beamer v3.67 on ctan tomorrow.
As a temporary workaround, place these two files in the folder of your .rmd file:
- https://raw.githubusercontent.com/josephwright/beamer/main/base/beamer.cls
- https://raw.githubusercontent.com/josephwright/beamer/main/base/beamerbasesection.sty
(don't forget to delete these files again once you have the new beamer version, otherwise they might interfere with future updates)