How do I set up mirror margins in R markdown using knitr

纵饮孤独 提交于 2019-12-11 03:13:52

问题


I know how to adjust the margins in an r markdown pdf file with the following:

---
title: "Model 1 Coefficients"
output: pdf_document
geometry: margin=1in
---

But I would like to make it so that the margin sizes switch between even and odd pages so that the inner margin is always 1.25 in and outer is always .25 in.

I was able to find some latex info on this website http://texdoc.net/texmf-dist/doc/latex/geometry/geometry.pdf and it seems like I want to use the twoside option but I'm not sure this is right or even how to call it. I tried the following:

---
title: "Model 1 Coefficients"
output: pdf_document
twoside: inner=1.25in, outer=0.25in
---

but that didn't do anything to the margins


回答1:


You will need something like this:

geometry: asymmetric

output:
    pdf_document:
        number_sections: TRUE
        fig_height: 3
        fig_width: 5

---

\pagenumbering{gobble}
\evensidemargin=0in
\oddsidemargin=0.5in


来源:https://stackoverflow.com/questions/30599293/how-do-i-set-up-mirror-margins-in-r-markdown-using-knitr

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!