forked from asalber/statistics-manual
-
Notifications
You must be signed in to change notification settings - Fork 0
/
statistics_manual.tex
221 lines (184 loc) · 5.94 KB
/
statistics_manual.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
% Author: Alfredo Sánchez Alberca ([email protected])
% !TEX program = xelatex
% ASPECT RATIO FOR YOUTUBE VIDEO
% \documentclass[aspectratio=1610,mathserif,profesionalfont,10pt,svgnames,red,xcolor=table]{beamer}
% ASPECT RATIO FOR PROJECTOR
% \documentclass[profesionalfont,10pt,svgnames,xcolor=table]{beamer}
% BEAMER THEME
% \usetheme[progressbar=frametitle,background=light,titleformat=smallcaps,block=fill]{metropolis}
% ARTICLE VERSION
% \pdfminorversion=4 % for solving some problems with png graphics in acrobat reader
\documentclass[10pt,a4paper,titlepage]{article}
\usepackage[hyperref]{beamerarticle}
% LANGUAGE
\usepackage{polyglossia}
\setdefaultlanguage{english}
% FONT
\mode<article>{
\usepackage{fontspec}
\setmainfont[Ligatures=TeX]{TeX Gyre Pagella}
\usepackage{unicode-math}
\setmathfont[math-style=ISO,bold-style=ISO]{TeX Gyre Pagella Math}
%\usepackage[sc]{mathpazo}
%\setromanfont[Mapping=tex-text]{Linux Libertine}
%\setsansfont[Mapping=tex-text]{Myriad Pro}
%\setmonofont[Mapping=tex-text]{Courier New}
}
% IMPROVE FONT IN PDF
\mode<article>{\usepackage{microtype}}
% MATHS
\usepackage{units}
% MARGINS
\setbeamersize{text margin left=.5cm, text margin right=.5cm}
% MARGINS FOR ARTICLE
\mode<article>{\usepackage{fullpage}}
\mode<article>{\usepackage[headsep=1cm, top=3cm, bottom=3cm, left=2.54cm, right=2.54cm]{geometry}}
% COLORS
\input{settings/colors.tex}
% TABLE OF CONTENT style
\setbeamertemplate{section in toc}[sections numbered]
\setbeamertemplate{subsection in toc}[subsections numbered]
% TABLES
\usepackage{array}
\usepackage{multirow}
\usepackage{colortbl}
\usepackage{booktabs}
\newcommand{\tcrule}{\arrayrulecolor{color1!50!white}\toprule}
\newcommand{\mcrule}{\arrayrulecolor{color1!50!white}\midrule}
\newcommand{\bcrule}{\arrayrulecolor{color1!50!white}\bottomrule}
% GRAPHICS
% GRAPHICS
\usepackage{pgfplots}
\usepgfplotslibrary{fillbetween}
% pgfplots styles
\input{settings/pgfplots}
\usepackage{tkz-euclide}
\usetkzobj{all}
\usepackage{tikz}
\usetikzlibrary{external, arrows, arrows.meta, calc, shapes, shapes.arrows, positioning, decorations.pathreplacing, intersections, fillbetween, snakes}
% TIKZ SETTINGS
\tikzset{
% Overlays
invisible/.style={opacity=0},
visible on/.style={alt={#1{}{invisible}}},
alt/.code args={<#1>#2#3}{%
\alt<#1>{\pgfkeysalso{#2}}{\pgfkeysalso{#3}} % \pgfkeysalso doesn't change the path
},
% Vectors
vector/.style={->, color1, thick},
% Arrow tips
>=stealth,
}
% Graphics export
\mode<article>{
\tikzset{
png export/.style={
external/system call={
xelatex \tikzexternalcheckshellescape -halt-on-error -interaction=batchmode -jobname "\image" "\texsource";
convert -density 300 -transparent white "\image.pdf" "\image.png"
}
}
}
\tikzset{
svg export/.style={
external/system call/.add={}%
{; pdf2svg "\image.pdf" "\image.svg"}
}
}
\tikzexternalize[prefix=img/exported/]
\tikzset{png export}
\tikzset{svg export}
}
\usepackage{graphicx}
% CREATIVE COMMON ICONS
\usepackage[scale=2]{ccicons}
% LOGO POSITION
\setbeamertemplate{title graphic}{
\vbox to 0pt {
\vspace*{0.9\textheight}
\inserttitlegraphic
}
}
% SPACE BETWEEN PARAGRAFS
\setlength{\parskip}{0.5em}
% THEOREM ENVIRONMENTS
%\theoremstyle{definition}
%\newtheorem{defin}[theorem]{Definition}
% BLOCKS COLORS
\setbeamercolor{block title}{
use=normal text,
fg=normal text.fg,
bg=alerted text.fg!50
}
% HEADINGS AND FOOTERS : Statistics manual
\mode<article>{
\usepackage{fancyhdr}
\pagestyle{fancy}
\rhead{\sffamily\slshape Elementary Statistics Manual}
\renewcommand{\headrulewidth}{0pt}
%\renewcommand{\floatpagefraction}{.8}
%\renewcommand{\textfraction}{.1}
}
% FRAME TITLE CONFIGURATION
% \defbeamertemplate{frametitle}{myframe}{
% \nointerlineskip
% \begin{beamercolorbox}[wd=\paperwidth,sep=1ex]{frametitle}
% \insertframetitle
% \end{beamercolorbox}
% }
% \setbeamertemplate{frametitle}[myframe]
% SECTION COLOR FOR ARTICLE
\mode<article>{
\usepackage{titlesec}
\titleformat{\section}{\color{color1}\normalfont\Large\bfseries}{\color{color1}\thesection}{1em}{}
\titleformat{\subsection}{\color{color1}\normalfont\large\bfseries}{\color{color1}\thesubsection}{1em}{}
}
% COMMAND FOR HIGHLIGHTING
\newcommand{\highlight}[1]{\textcolor{orange}{\textbf{#1}}}
% PDF settings
\hypersetup{colorlinks=true}
%=====================================================================BODY=====
%---------------------------------------------------------------------cover----
\mode<article>{
\title{\vskip 3cm
\textcolor{color1}{\Huge Elementary Statistics Manual}}
\author{
%Pablo Ares Gastesi (\href{mailto:[email protected]}{[email protected]}) \and
Alfredo Sánchez Alberca (\href{mailto:[email protected]}{[email protected]})
}
\date{Jan 2018\\[1cm]
Department of Applied Math and Statistics\\ CEU San Pablo\\[1cm]
\includegraphics[height=2cm]{img/logo_uspceu}
}
}
\mode<presentation>{
\title{Elementary Statistics Manual}
\author{
Pablo Ares Gastesi (\href{mailto:[email protected]}{[email protected]}) \\
Alfredo Sánchez Alberca (\href{mailto:[email protected]}{[email protected]})
}
\institute{Department of Applied Math and Statistics\\ CEU San Pablo}
\date{Jan 2018}
\titlegraphic{\hfill\includegraphics[height=1.5cm]{img/logo_uspceu}}
}
\begin{document}
\mode<article>{\thispagestyle{empty}\maketitle}
\mode<presentation>{\maketitle}
%---------------------------------------------------------------------slide----
\begin{frame}
\input{preamble/license}
\end{frame}
\mode<article>{\clearpage}
%---------------------------------------------------------------------slide----
\begin{frame}
\mode<presentation>{\frametitle{Contents}}
\setbeamertemplate{section in toc}[sections numbered]
\tableofcontents[hideallsubsections]
\end{frame}
\include{chapters/introduction}
\include{chapters/descriptive}
\include{chapters/regression}
\include{chapters/probability}
\include{chapters/discrete_random_variables}
\include{chapters/continuous_random_variables}
\end{document}