how to add a glossary/acronym list on a Rmarkdown (rticle template) file?

Hi,
I am using the MDPI rticles template and keen to also use the glossarie packages so I don't have to manually feed all the abbreviation on the appropriate YAML field.

For such, I have loaded the LaTex package glossaries using the header-includes:

header-includes:
\usepackage{inputenc}
\usepackage[acronym, section=section]{glossaries}
\setacronymstyle{long-short}
\makeglossaries
\makeindex
\input{glossary}

after creating several acronyms within the Rmarkdown body, I would be willing to input the raw LaTex:
\begin{abbreviations}
\printglossary[type=\acronymtype,title={List of Acronyms}]
\end{abbreviations}

However nothing gets printed.
Any ideas? A couple of .gls and glsdef files are automatically created (and not used I assume)

1 Like

Hello,

I can hack it through the following (I am sure there is a better way):
1- keep all the aux files
chunk with : options(tinytex.clean = FALSE)

2- makeglossaries "filename"

3-
\begin{abbreviations}

\setabbreviationstyle[acronym]{long-short}
\printglossary[type=\acronymtype,title={}]

\end{abbreviations}

However, I would be keen to know if I could insert something on the YAML and use the MDPI formatting?
Any ideas

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