Include the text of a `bibentry` in the (R)markdown text body output

Viewed 1265
1 Answers

A reasonable solution is to read and parse the bibliography database using, for example, the R-package bibtex and then capture.output of print as a character string, which can then be used to include the full text of a reference item (bibentry) in the body of the (R)markdown text document.

For example:

```{r, echo=FALSE}
biblio <- bibtex::read.bib("my-biblio-database.bib")
```

Then, in line, use:

`r capture.output(print(biblio["my-bibkey"]))`

which will print the reference text.

Related