4

I am getting a very annoying error when I try to run rmarkdown docs knitting to pdf from mac

output file: Untitled2.knit.md

! LaTeX Error: File `titling.sty' not found.

Does anyone know a simple solution? I think what caused it was trying to re-install MacTex.

llewmills
  • 2,959
  • 3
  • 31
  • 58

3 Answers3

4

There is a discussion about this problem here.

It probably means your TeX installation is incomplete. I had the same problem on Ubuntu because I installed texlive instead of texlive-full.

James Hirschorn
  • 7,032
  • 5
  • 45
  • 53
1

Two possible problems: 1) have you used \usepackage {titling} in your front matter? 2) after you reinstalled MacTex, did you install titling into your tex library?

Benjamin
  • 16,897
  • 6
  • 45
  • 65
1

The package in question is meant for typesetting in titling. Read about it on the archives here: https://www.ctan.org/pkg/titling.

You can install it through the MacOS utility that TeXlive provides in /Applications/TeX (http://amaxwell.github.io/tlutility/). Hope this helps.

Hanzai
  • 11
  • 3