34

I try to reference to a single footnote in a few places in the text. However, with the code below, I've got two footnotes with the same content.

---
title: "My document"
output: html_document
---

One part of the text [^1].

Two pages later [^1].

[^1]: My footnote

enter image description here

Is it possible to reference more than once to a specific footnote using rmarkdown?

Jot eN
  • 6,120
  • 4
  • 40
  • 59
  • 2
    See https://github.com/jgm/pandoc/issues/1603, a general solution does not seem to exist yet. But I guess (hope) there are solution specific to HTML document. – Vincent Guillemot Sep 08 '17 at 13:53
  • 2
    If you are open to knitr and external packages like `fixfoot` see this [reference-different-places-to-the-same-footnote](https://tex.stackexchange.com/questions/35043/reference-different-places-to-the-same-footnote) – Silence Dogood Sep 08 '17 at 13:55

3 Answers3

2

I had the same problem. I used html tags which worked really well. Whatever you want as superscript just put between the <\sup> like below:

<sup> text </sup>

jan 6 2023 update: now I use quarto which is eally easy as you can just use do[^1]

[^1]footnote text

alejandro_hagan
  • 843
  • 2
  • 13
1

My workaround here is to just do it manually using inline latex mathmode (e.g, \(^2\) ).. Annoying, but even if they had a solution, you'd have to remember the citation number anyways...

bboppins
  • 11
  • 2
0

I would suggest you to go with latex solution if you do not have many footnotes per page. By latex solution I mean:

(in Markdown, use Latex to superscript the footnote number)

First part$^1$

(and the next one)

Second part$^2$

(at the end of your text add *** to create a line across the document)

(under the line, add the text below:)

1, 2: Text for your footnote

On the other hand, there is a thread created on this specific R-Markdown bug. Maybe take a look at it, in this link.

Hope I helped somehow.

TheKrab
  • 21
  • 5