10:00
Session 7–PDF Documents
Download the Quarto files for this session and the previous one here
tinytex
package installed
quarto install tinytex
session-2.3.qmd
file::: - Quarto uses LaTex to render standard PDFs - LaTex is a typesetting system that is widely used for technical and scientific documents - Quarto uses LaTex to create PDFs from your markdown files - Uses knitr
to do the conversion - There is also something called typst
that we will explore later :::
---
title: "My Paper"
subtitle: "An Example of a Quarto Paper"
author:
- name: Bullwinkle J. Moose
- name: Rocky the Flying Squirrel
format:
pdf:
documentclass: article
date: today
date-format: long
abstract: |
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. More Latin.
link-citations: true
#link-bibliography: false
colorlinks: true
linkcolor: Blue4
fig-width: 6.5
fig-height: 4.5
fig-cap-location: top
block-headings: false # so that titlesec package works
geometry: margin = 1in
fontsize: 12pt
mainfont: Times New Roman
mathfont: STIX Two Math
linestretch: 2
indent: true
bibliography: references.bib
#cite-method: biblatex
#biblio-style: apa
#csl: american-political-science-association.csl
reference-section-title: References
execute:
echo: false
message: false
warning: false
include-in-header: header.tex
---
abstract: |
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. More Latin.
Note that fonts are defined by system fonts. System fonts are defined by the operating system and differ across Macs and PCs.
What is in the header.tex
file?
%%% Setup for frontmatter and spacing %%%
\usepackage{indentfirst} % indent first para
\setlength{\parindent}{0.5in} % set indent length
\setlength{\parskip}{0em} % no extra space between paras
\usepackage{titlesec} % to set spacing of section titles
\titlespacing\section{0pt}{0pt plus 2pt minus 2pt}{0pt plus 2pt minus 2pt}
\titlespacing\subsection{0pt}{0pt plus 2pt minus 2pt}{0pt plus 2pt minus 2pt}
\titlespacing\subsubsection{0pt}{0pt plus 2pt minus 2pt}{0pt plus 2pt minus 2pt}
What is in the header.tex
file?
%%% Captions %%%
\usepackage{caption}
\captionsetup{
%captionskip = 0pt, % eliminate space bw capiton and figure
%labelformat = empty, % eliminate caption label
%font = bf,
justification = raggedright, % left justify the caption
singlelinecheck = true, % but only if it is more than one line
font = footnotesize, % make font smaller
labelfont = bf % make the caption label bold
}
10:00
.bib
files.bib
files are a way to store references.bib
file
.bib
file that is easier to read and edit.bib
file to our project folder[@authorXXXX]
csl
file in the YAML headerbiblio-style
in the YAML headercsl
file is a style file that can be found herebiblio-style
is a style that can be found here
apa
, mla
or chicago-authordate
in the social science10:00
quarto use template repo-name/extension-name
quarto add repo-name/extension-name