-
Notifications
You must be signed in to change notification settings - Fork 1
/
APA_Template.tex
242 lines (179 loc) · 7.55 KB
/
APA_Template.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
\documentclass[english,man]{apa6}
\usepackage{amssymb,amsmath}
\usepackage{ifxetex,ifluatex}
\usepackage{fixltx2e} % provides \textsubscript
\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\else % if luatex or xelatex
\ifxetex
\usepackage{mathspec}
\usepackage{xltxtra,xunicode}
\else
\usepackage{fontspec}
\fi
\defaultfontfeatures{Mapping=tex-text,Scale=MatchLowercase}
\newcommand{\euro}{€}
\fi
% use upquote if available, for straight quotes in verbatim environments
\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
% use microtype if available
\IfFileExists{microtype.sty}{\usepackage{microtype}}{}
% Table formatting
\usepackage{longtable, booktabs}
\usepackage{lscape}
% \usepackage[counterclockwise]{rotating} % Landscape page setup for large tables
\usepackage{multirow} % Table styling
\usepackage{tabularx} % Control Column width
\usepackage[flushleft]{threeparttable} % Allows for three part tables with a specified notes section
\usepackage{threeparttablex} % Lets threeparttable work with longtable
% Create new environments so endfloat can handle them
\newenvironment{ltable}
{\begin{landscape}\begin{center}\begin{threeparttable}}
{\end{threeparttable}\end{center}\end{landscape}}
\newenvironment{lltable}
{\begin{landscape}\begin{center}\begin{ThreePartTable}}
{\end{ThreePartTable}\end{center}\end{landscape}}
\usepackage{ifthen} % Only add declarations when endfloat package is loaded
\ifthenelse{\equal{man}{\string jou}}{%
\DeclareDelayedFloatFlavor{ThreePartTable}{table} % Make endfloat play with longtable
\DeclareDelayedFloatFlavor{ltable}{table} % Make endfloat play with lscape
\DeclareDelayedFloatFlavor{lltable}{table} % Make endfloat play with lscape & longtable
}{}%
% The following enables adjusting longtable caption width to table width
% Solution found at http://golatex.de/longtable-mit-caption-so-breit-wie-die-tabelle-t15767.html
\makeatletter
\newcommand\LastLTentrywidth{1em}
\newlength\longtablewidth
\setlength{\longtablewidth}{1in}
\newcommand\getlongtablewidth{%
\begingroup
\ifcsname LT@\roman{LT@tables}\endcsname
\global\longtablewidth=0pt
\renewcommand\LT@entry[2]{\global\advance\longtablewidth by ##2\relax\gdef\LastLTentrywidth{##2}}%
\@nameuse{LT@\roman{LT@tables}}%
\fi
\endgroup}
\ifxetex
\usepackage[setpagesize=false, % page size defined by xetex
unicode=false, % unicode breaks when used with xetex
xetex]{hyperref}
\else
\usepackage[unicode=true]{hyperref}
\fi
\hypersetup{breaklinks=true,
pdfauthor={},
pdftitle={The title},
colorlinks=true,
citecolor=blue,
urlcolor=blue,
linkcolor=black,
pdfborder={0 0 0}}
\urlstyle{same} % don't use monospace font for urls
\setlength{\parindent}{0pt}
%\setlength{\parskip}{0pt plus 0pt minus 0pt}
\setlength{\emergencystretch}{3em} % prevent overfull lines
\setcounter{secnumdepth}{0}
\ifxetex
\usepackage{polyglossia}
\setmainlanguage{}
\else
\usepackage[english]{babel}
\fi
% Manuscript styling
\captionsetup{font=singlespacing,justification=justified}
\usepackage{csquotes}
\usepackage{upgreek}
% Line numbering
\usepackage{lineno}
\linenumbers
\usepackage{tikz} % Variable definition to generate author note
% fix for \tightlist problem in pandoc 1.14
\providecommand{\tightlist}{%
\setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}}
% Essential manuscript parts
\title{The title}
\shorttitle{Title}
\author{First Author\textsuperscript{1}~\& Ernst-August Doelle\textsuperscript{1,2}}
\def\affdep{{"", ""}}%
\def\affcity{{"", ""}}%
\affiliation{
\vspace{0.5cm}
\textsuperscript{1} Wilhelm-Wundt-University\\
\textsuperscript{2} Konstanz Business School }
\authornote{
\newcounter{author}
Complete departmental affiliations for each author (note the
indentation, if you start a new paragraph). Enter author note here.
Correspondence concerning this article should be addressed to First Author, Postal address. E-mail: \href{mailto:[email protected]}{\nolinkurl{[email protected]}}
}
\abstract{Enter abstract here (note the indentation, if you start a new
paragraph).}
\keywords{keywords \\
\indent Word count: X
}
\begin{document}
\maketitle
\section{Methods}\label{methods}
We report how we determined our sample size, all data exclusions (if
any), all manipulations, and all measures in the study.
\subsection{Participants}\label{participants}
\subsection{Material}\label{material}
\subsection{Procedure}\label{procedure}
\subsection{Data analysis}\label{data-analysis}
We used R (3.3.1, R Core Team, 2016) and the R-packages \emph{dplyr}
(0.5.0, Wickham \& Francois, 2016), \emph{ggplot2} (2.1.0, Wickham,
2009), \emph{gridExtra} (2.2.1, Auguie, 2016), \emph{knitr} (1.15.1,
Xie, 2015), \emph{papaja} (0.1.0.9440, Aust \& Barth, 2016),
\emph{purrr} (0.2.2, Wickham, 2016a), \emph{readr} (1.0.0, Wickham,
Hester, \& Francois, 2016), \emph{tibble} (1.2, Wickham, Francois, \&
Müller, 2016), \emph{tidyr} (0.6.0, Wickham, 2017), and \emph{tidyverse}
(1.0.0, Wickham, 2016b) for all our analyses.
\section{Results}\label{results}
\section{Discussion}\label{discussion}
\newpage
\section{References}\label{references}
\setlength{\parindent}{-0.5in} \setlength{\leftskip}{0.5in}
\hypertarget{refs}{}
\hypertarget{ref-R-gridExtra}{}
Auguie, B. (2016). \emph{GridExtra: Miscellaneous functions for ``grid''
graphics}. Retrieved from
\url{https://CRAN.R-project.org/package=gridExtra}
\hypertarget{ref-R-papaja}{}
Aust, F., \& Barth, M. (2016). \emph{Papaja: Create aPA manuscripts with
rMarkdown}. Retrieved from \url{https://github.com/crsh/papaja}
\hypertarget{ref-R-base}{}
R Core Team. (2016). \emph{R: A language and environment for statistical
computing}. Vienna, Austria: R Foundation for Statistical Computing.
Retrieved from \url{https://www.R-project.org/}
\hypertarget{ref-R-ggplot2}{}
Wickham, H. (2009). \emph{Ggplot2: Elegant graphics for data analysis}.
Springer-Verlag New York. Retrieved from \url{http://ggplot2.org}
\hypertarget{ref-R-purrr}{}
Wickham, H. (2016a). \emph{Purrr: Functional programming tools}.
Retrieved from \url{https://CRAN.R-project.org/package=purrr}
\hypertarget{ref-R-tidyverse}{}
Wickham, H. (2016b). \emph{Tidyverse: Easily install and load
'tidyverse' packages}. Retrieved from
\url{https://CRAN.R-project.org/package=tidyverse}
\hypertarget{ref-R-tidyr}{}
Wickham, H. (2017). \emph{Tidyr: Easily tidy data with 'spread()' and
'gather()' functions}. Retrieved from
\url{https://CRAN.R-project.org/package=tidyr}
\hypertarget{ref-R-dplyr}{}
Wickham, H., \& Francois, R. (2016). \emph{Dplyr: A grammar of data
manipulation}. Retrieved from
\url{https://CRAN.R-project.org/package=dplyr}
\hypertarget{ref-R-tibble}{}
Wickham, H., Francois, R., \& Müller, K. (2016). \emph{Tibble: Simple
data frames}. Retrieved from
\url{https://CRAN.R-project.org/package=tibble}
\hypertarget{ref-R-readr}{}
Wickham, H., Hester, J., \& Francois, R. (2016). \emph{Readr: Read
tabular data}. Retrieved from
\url{https://CRAN.R-project.org/package=readr}
\hypertarget{ref-R-knitr}{}
Xie, Y. (2015). \emph{Dynamic documents with R and knitr} (2nd ed.).
Boca Raton, Florida: Chapman; Hall/CRC. Retrieved from
\url{http://yihui.name/knitr/}
\end{document}