rmarkdown problem rendering subtitle specified in second yaml chunk

With the following document, I am trying to generate a subtitle dynamically. This works with Rmarkdown as long as pandoc is sufficiently new. But with an older version of pandoc, e.g. 1.16 from 2015, although the document compiles, there is no subtitle.

---
output:
  pdf_document:
    keep_tex: true
    toc: false
---

```{r rsetup,eval=TRUE,include=FALSE}
require(knit)
x = 1
y = "link to DOI"

```

---
title: `r paste("CODECHECK certificate", x)`
subtitle: `r y`
---

What's the question here? Do you want it to work on earlier versions of pandoc?

Mark

Yes, would be nice if it worked across older pandocs (as I thought it would from looking at code that inserts subtitle). Some of my colleagues are working on systems that have older pandocs.

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.