forked from jeroen/r-dependency-versioning
-
Notifications
You must be signed in to change notification settings - Fork 0
/
RJournal.sty.new
207 lines (205 loc) · 6.8 KB
/
RJournal.sty.new
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
%%
%% This is file `RJournal.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% RJournal.dtx (with options: `package')
%%
\def\fileversion{v0.11}
\def\filename{RJournal}
\def\filedate{2013/01/11}
\def\docdate {2013/01/11}
%%
%% Package `RJournal' to use with LaTeX2e
%% Copyright (C) 2010 by the R Foundation
%%
%% -*- LaTeX -*-
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesPackage{\filename}[\filedate\space\fileversion\space
RJournal package]
\typeout{Package: `\filename\space\fileversion \@spaces <\filedate>'}
\typeout{English documentation as of <\docdate>}
\RequirePackage[pagebackref]{hyperref}
\renewcommand{\backref}[1]{[p#1]}
\RequirePackage{ifthen}
\newboolean{RJ@driver}
\DeclareOption{driver}{\setboolean{RJ@driver}{true}}
\DeclareOption*{\PackageWarning{\filename}{Unknown option
`\CurrentOption'}}
\ProcessOptions\relax
\ifthenelse{\boolean{RJ@driver}}{}{
\RequirePackage{tikz}
\RequirePackage{graphicx,color,fancyhdr}
\RequirePackage{amsmath}
\RequirePackage{placeins}
\IfFileExists{upquote.sty}{\RequirePackage{upquote}}{}
\newcommand{\volume}[1]{\def\RJ@volume{#1}}
\newcommand{\volnumber}[1]{\def\RJ@number{#1}}
\renewcommand{\date}[1]{\def\RJ@date{#1}}
\setcounter{secnumdepth}{-1}
\newcommand{\sectionhead}[1]{\def\RJ@sectionhead{#1}}
\renewcommand{\author}[1]{\def\RJ@author{#1}}
\renewcommand{\title}[1]{\def\RJ@title{#1}}
\newcommand{\subtitle}[1]{\def\RJ@subtitle{#1}}
\newenvironment{article}{\author{}\title{}\subtitle{}\FloatBarrier}{\FloatBarrier}
\renewcommand{\maketitle}{
\chapter{\RJ@title}\refstepcounter{chapter}
\ifx\empty\RJ@subtitle\else\noindent\textbf{\RJ@subtitle}
\par\nobreak\addvspace{\baselineskip}\fi
\ifx\empty\RJ@author\else\noindent\textit{\RJ@author}
\par\nobreak\addvspace{\baselineskip}\fi
\@afterindentfalse\@nobreaktrue\@afterheading}
\renewcommand\chapter{\secdef\RJ@chapter\@schapter}
\providecommand{\nohyphens}{%
\hyphenpenalty=10000\exhyphenpenalty=10000\relax}
\newcommand{\RJ@chapter}{%
\edef\name@of@eq{equation.\@arabic{\c@chapter}}%
\renewcommand{\@seccntformat}[1]{}%
\@startsection{chapter}{0}{0mm}{%
-2\baselineskip \@plus -\baselineskip \@minus -.2ex}{\p@}{%
\phantomsection\normalfont\Huge\bfseries\raggedright}}
\renewcommand*\l@chapter{\@dottedtocline{0}{0pt}{1em}}
\newcommand{\review}[1]{
\pdfbookmark[1]{#1}{#1}
\section*{#1}
\addtocontents{toc}{\protect\contentsline{chapter}{#1}{\thepage}{#1.1}}
}
\renewcommand{\abstract}[1]{\begin{center}\begin{minipage}{0.92\linewidth}
\textbf{Abstract } #1 \end{minipage}\end{center} \subsubsection{} \vspace{-12pt}}
\def\@schapter#1{\section*#1}
\numberwithin{equation}{chapter}
\renewcommand{\theequation}{\@arabic\c@equation}
\renewcommand{\thefigure}{\@arabic\c@figure}
\renewcommand{\thetable}{\@arabic\c@table}
\renewcommand{\contentsname}{Contents}
\renewcommand\tableofcontents{%
\begin{center}
\vspace{1cm}
\begin{tikzpicture}
\node[right,text width=15.5cm, draw=black, rounded corners=20pt,
fill=white,inner sep=2em, very thick]
{
\begin{minipage}[t][16.5cm][c]{1.0\linewidth}
\section*{\contentsname}
{
\@starttoc{toc}
}
\end{minipage}
};
\end{tikzpicture}
\end{center}}
\renewcommand{\titlepage}{%
\hypersetup{
pdftitle={The R Journal Volume \RJ@volume/\RJ@number, \RJ@date},%
pdfauthor={R Foundation for Statistical Computing},%
}
\noindent
\begin{center}
\fontsize{60pt}{60pt}\selectfont
The \raisebox{-8pt}{\includegraphics[height=77pt]{Rlogo-4}}\hspace{10pt}
Journal
\end{center}
{\large\hfill Volume \RJ@volume/\RJ@number, \RJ@date\qquad}
\\[-.5\baselineskip]
\rule{\textwidth}{1pt}
\begin{center}
{\Large A peer-reviewed, open-access publication of the R Foundation\\
for Statistical Computing}
\end{center}
\fancyhf{}
\fancyhead[LO,RE]{\textsc{\RJ@sectionhead}}
\fancyhead[RO,LE]{\thepage}
\fancyfoot[L]{The R Journal Vol. \RJ@volume/\RJ@number, \RJ@date}
\fancyfoot[R]{ISSN 2073-4859}
\thispagestyle{empty}
\setcounter{tocdepth}{0}
\tableofcontents
\setcounter{tocdepth}{2}
\clearpage
}
\setlength{\textheight}{250mm}
\setlength{\topmargin}{-10mm}
\setlength{\textwidth}{17cm}
\setlength{\oddsidemargin}{-6mm}
\setlength{\evensidemargin}{-6mm}
%% sf & almost european \\
\RequirePackage{pslatex}
\RequirePackage{palatino,mathpazo}
\RequirePackage[T1]{fontenc}
\definecolor{link}{rgb}{0,0,0.3}
\hypersetup{
colorlinks,%
citecolor=link,%
filecolor=link,%
linkcolor=link,%
urlcolor=link
}
\newcommand{\R}{R}
\newcommand{\address}[1]{\addvspace{\baselineskip}\noindent\emph{#1}}
\newcommand{\email}[1]{\href{mailto:#1}{\normalfont\texttt{#1}}}
\RequirePackage{verbatim}
\def\boxedverbatim{%
\def\verbatim@processline{%
{\setbox0=\hbox{\the\verbatim@line}%
\hsize=\wd0 \the\verbatim@line\par}}%
\@minipagetrue
\@tempswatrue
\setbox0=\vbox
\bgroup\small\verbatim
}
\def\endboxedverbatim{%
\endverbatim
\unskip\setbox0=\lastbox
\egroup
\fbox{\box0}
}
\pagestyle{fancy}
} % \ifthenelse{\boolean{RJ@driver}}
\DeclareRobustCommand\code{\bgroup\@noligs\@codex}
\def\@codex#1{\texorpdfstring%
{{\normalfont\ttfamily\hyphenchar\font=-1 #1}}%
{#1}\egroup}
\newcommand{\kbd}[1]{{\normalfont\texttt{#1}}}
\newcommand{\key}[1]{{\normalfont\texttt{\uppercase{#1}}}}
\DeclareRobustCommand\samp{`\bgroup\@noligs\@sampx}
\def\@sampx#1{{\normalfont\texttt{#1}}\egroup'}
\newcommand{\var}[1]{{\normalfont\textsl{#1}}}
\let\env=\code
\newcommand{\file}[1]{{`\normalfont\textsf{#1}'}}
\let\command=\code
\let\option=\samp
\newcommand{\dfn}[1]{{\normalfont\textsl{#1}}}
\newcommand{\acronym}[1]{#1}
\newcommand{\strong}[1]{\texorpdfstring%
{{\normalfont\fontseries{b}\selectfont #1}}%
{#1}}
\let\pkg=\strong
\newcommand{\CRANpkg}[1]{\href{http://CRAN.R-project.org /package=#1}{\pkg{#1}}}%
\let\cpkg=\CRANpkg
\newcommand{\ctv}[1]{\href{http://CRAN.R-project.org/view=#1}{\emph{#1}}}
\RequirePackage{alltt}
\newenvironment{example}{\begin{alltt}}{\end{alltt}}
\newenvironment{smallexample}{\begin{alltt}\small}{\end{alltt}}
\newenvironment{display}{\list{}{}\item\relax}{\endlist}
\newenvironment{smallverbatim}{\small\verbatim}{\endverbatim}
\RequirePackage{fancyvrb}
\DefineVerbatimEnvironment{Sinput}{Verbatim}{fontsize=\small}
\DefineVerbatimEnvironment{Soutput}{Verbatim}{fontsize=\small}
\DefineVerbatimEnvironment{Scode}{Verbatim}{fontsize=\small}
\DefineVerbatimEnvironment{Sin}{Verbatim}{fontsize=\small}
\DefineVerbatimEnvironment{Sout}{Verbatim}{fontsize=\small}
\newenvironment{Schunk}{}{}
\providecommand{\operatorname}[1]{%
\mathop{\operator@font#1}\nolimits}
\renewcommand{\P}{%
\mathop{\operator@font I\hspace{-1.5pt}P\hspace{.13pt}}}
\newcommand{\E}{%
\mathop{\operator@font I\hspace{-1.5pt}E\hspace{.13pt}}}
\newcommand{\VAR}{\operatorname{var}}
\newcommand{\COV}{\operatorname{cov}}
\newcommand{\COR}{\operatorname{cor}}
\RequirePackage{amsfonts}
\endinput
%%
%% End of file `RJournal.sty'.