Debian Codegraph @

texmf-dist/tex/latex/lwarp/lwarp-statex2.sty

raw
1 %%
2 %% This is file `lwarp-statex2.sty',
3 %% generated with the docstrip utility.
4 %%
5 %% The original source files were:
6 %%
7 %% lwarp.dtx (with options: `statex2')
8 %% This is a generated file.
9 %% Copyright 2016-2026 Brian Dunn
10 %%
11 %% This work may be distributed and/or modified under the
12 %% conditions of the LaTeX Project Public License, either version 1.3
13 %% of this license or (at your option) any later version.
14 %% The latest version of this license is in
15 %% http://www.latex-project.org/lppl.txt
16 %% and version 1.3 or later is part of all distributions of LaTeX
17 %% version 2005/12/01 or later.
18
19 \LWR@ProvidesPackagePass{statex2}[2011/09/14]
20 \newcommand*{\LWR@HTML@Alpha}[1][]{%
21 \fcolorbox{black}{ForestGreen}{\textcolor{white}{\textsf{ALPHA}}}%
22 \textbf{\textcolor{ForestGreen}{\textsf{#1}}}%
23 }
24 \LWR@formatted{Alpha}
25
26 \newcommand*{\LWR@HTML@List}[1]{%
27 \textbf{\textcolor{Dandelion}{\textsf{L}\textsubscript{\textit{#1}}}}%
28 }
29 \LWR@formatted{List}
30
31 \newcommand*{\LWR@HTML@Snd}[1][]{%
32 \fcolorbox{black}{Dandelion}{\textcolor{white}{\textsf{2nd}}}%
33 \textbf{\textcolor{Dandelion}{\textsf{#1}}}%
34 }
35 \LWR@formatted{Snd}
36
37 \begin{warpMathJax}
38 \LWR@infoprocessingmathjax{statex2}
39
40 \CustomizeMathJax{\newcommand{\cpi}{\boldsymbol{\pi}}}
41 \CustomizeMathJax{\newcommand{\c}[1]{\boldsymbol{\mathrm{#1}}}}
42 \CustomizeMathJax{\newcommand{\sfsl}[1]{\mathsf#1}}% not slanted
43
44 \if@manualbold
45 \CustomizeMathJax{\newcommand{\mb}[1]{#1}}
46 \else
47 \CustomizeMathJax{\newcommand{\mb}[1]{\boldsymbol{#1}}}
48 \fi
49
50 \CustomizeMathJax{\newcommand{\diag}{\mb{\mathrm{diag}}}}
51 \CustomizeMathJax{\newcommand{\blockdiag}{\mb{\mathrm{blockdiag}}}}
52 \CustomizeMathJax{\newcommand{\erf}{\mb{\mathrm{erf}}}}
53 \CustomizeMathJax{\newcommand{\logit}{\mb{\mathrm{logit}}}}
54 \CustomizeMathJax{\newcommand{\trace}{\mb{\mathrm{trace}}}}
55
56 \CustomizeMathJax{\newcommand{\chisq}{{\mb{\chi^2}}}}
57 \CustomizeMathJax{\newcommand{\deriv}[2]{\mb{\frac{\d{}}{\d{#1}}}\wrap{\mb{#2}}}}
58 \CustomizeMathJax{\newcommand{\derivf}[2]{\mb{\frac{\d{}}{\d{#2}}}\wrap{\mb{#1}}}}
59 \CustomizeMathJax{\newcommand{\e}[1]{\mb{\mathrm{e}^{#1}}}}
60 \CustomizeMathJax{\newcommand{\E}[2][]{\mb{\mathrm{E}}_{\mb{#1}} \wrap{\mb{#2}}}}
61 \CustomizeMathJax{\newcommand{\ha}{{\mb{\frac{\alpha}{2}}}}}
62 \CustomizeMathJax{\newcommand{\I}[2][]{%
63 \mb{\mathrm{I}}_{\mb{#1}} \LWRwrapparen{\mb{#2}}%
64 }}
65 \CustomizeMathJax{\newcommand{\IBeta}[2]{%
66 \mb{\frac{\Gamma[#1+#2]}{\Gamma[#1]\Gamma[#2]}}%
67 }}
68 \CustomizeMathJax{\newcommand{\If}{\;\mb{\mathrm{if}}\;}}
69 \CustomizeMathJax{\newcommand{\im}{\mb{\mathrm{i}}}}
70 \CustomizeMathJax{\newcommand{\ol}{\overline}}
71 \CustomizeMathJax{\newcommand{\ow}{\;\mb{\mathrm{otherwise}}\;}}
72 \CustomizeMathJax{\newcommand{\pderiv}[2]{%
73 \mb{\frac{\partial}{\partial #1}}\wrap{\mb{#2}}%
74 }}
75 \CustomizeMathJax{\newcommand{\pderivf}[2]{%
76 \mb{\frac{\partial}{\partial #2}}\wrap{\mb{#1}}%
77 }}
78 \CustomizeMathJax{\newcommand{\sd}{\mb{\sigma}}}
79 \CustomizeMathJax{\newcommand{\ul}{\underline}}
80 \CustomizeMathJax{\newcommand{\V}[2][]{\mb{\mathrm{V}}_{\mb{#1}} \wrap{\mb{#2}}}}
81 \CustomizeMathJax{\newcommand{\vs}{\;\mb{\mathrm{vs.}}\;}}
82 \CustomizeMathJax{\newcommand{\where}{\;\mb{\mathrm{where}}\;}}
83 \CustomizeMathJax{\newcommand{\wrap}[2][]{\left[ #2 \right]}}% only []
84 \CustomizeMathJax{\newcommand{\LWRwrapparen}[1]{\left( #1 \right)}}% lwarp
85
86
87 \CustomizeMathJax{\newcommand{\iid}{\;\stackrel{\mb{\mathrm{iid}}}{\sim}\;}}
88 \CustomizeMathJax{\newcommand{\ind}{\;\stackrel{\mb{\mathrm{ind}}}{\sim}\;}}
89 \CustomizeMathJax{\newcommand{\indpr}{%
90 \;\stackrel{\mb{\mathrm{ind}}}{\stackrel{\mb{\mathrm{prior}}}{\sim}}\;
91 }}
92 \CustomizeMathJax{\newcommand{\post}{\;\stackrel{\mb{\mathrm{post}}}{\sim}\;}}
93 \CustomizeMathJax{\newcommand{\prior}{\;\stackrel{\mb{\mathrm{prior}}}{\sim}\;}}
94
95 \CustomizeMathJax{\let\STATEXGamma=\Gamma}
96 \CustomizeMathJax{\renewcommand{\Gamma}[1][]{\mb{\STATEXGamma}\LWRwrapparen{\mb{#1}}}}
97 \CustomizeMathJax{\renewcommand{\and}{\;\mb{\mathrm{and}}\;}}
98 \CustomizeMathJax{\newcommand{\H}{\mb{\mathrm{H}}}}
99 \CustomizeMathJax{\newcommand{\P}[2][]{\mb{\mathrm{P}}_{\mb{#1}}\wrap{\mb{#2}}}}
100 \CustomizeMathJax{\newcommand{\|}{\mb{\mid}}}
101
102 \CustomizeMathJax{\newcommand{\B}[1]{\mb{\mathrm{B}}\LWRwrapparen{\mb{#1}}}}
103 \CustomizeMathJax{\newcommand{\BB}[1]{\mb{\mathrm{BetaBin}}\LWRwrapparen{\mb{#1}}}}
104 \CustomizeMathJax{\newcommand{\Bin}[2]{\mb{\mathrm{Bin}}\LWRwrapparen{\mb{#1,\ #2}}}}
105 \CustomizeMathJax{\newcommand{\Dir}[1]{\mb{\mathrm{Dirichlet}}\LWRwrapparen{\mb{#1}}}}
106 \CustomizeMathJax{\newcommand{\HG}[3]{%
107 \mb{\mathrm{Hypergeometric}}\LWRwrapparen{\mb{#1,\ #2,\ #3}}%
108 }}
109 \CustomizeMathJax{\newcommand{\M}[2]{%
110 \mb{\mathrm{Multinomial}}\LWRwrapparen{\mb{#1,\ #2}}%
111 }}
112 \CustomizeMathJax{\newcommand{\NB}[2]{\mb{\mathrm{NegBin}}\LWRwrapparen{\mb{#1,\ #2}}}}
113 \CustomizeMathJax{\newcommand{\Poi}[1]{\mb{\mathrm{Poisson}}\LWRwrapparen{\mb{#1}}}}
114 \CustomizeMathJax{\let\Poisson=\Poi}
115
116 \CustomizeMathJax{\newcommand{\pBB}[4][x]{%
117 \mb{\frac{\Gamma[#2+1]\Gamma[#3+#1]\Gamma[#2+#4-#1]\Gamma[#3+#4]}%
118 {\Gamma[#1+1]\Gamma[#2-#1+1]\Gamma[#2+#3+#4]\Gamma[#3]\Gamma[#4]}%
119 \I[#1]{\{0, 1,\., #2\}}, \where #3>0,\; #4>0 \and n=1, 2,\.}%
120 }}
121 \CustomizeMathJax{\newcommand{\pBin}[3][x]{%
122 \mb{\binom{#2}{#1}#3^{#1}} \LWRwrapparen{\mb{{1-#3}^{#2-#1}}}%
123 \mb{\I[#1]{\{0,1,\.,#2\}}, \where p \in (0, 1) \and n=1, 2,\.}%
124 }}
125 \CustomizeMathJax{\newcommand{\pPoi}[2][x]{%
126 \mb{\frac{1}{#1!}#2^{#1}\e{-#2}\I[#1]{\{0, 1,\.\}}, \where #2>0}%
127 }}
128
129 \CustomizeMathJax{\newcommand{\Cau}[2]{\mb{\mathrm{Cauchy}}\LWRwrapparen{\mb{#1,\ #2}}}}
130 \CustomizeMathJax{\let\Cauchy=\Cau}
131 \CustomizeMathJax{\newcommand{\Chi}[2][]{%
132 \chisq_{\mb{#1}}\LWRwrapparen{\mb{#2}}%
133 }}
134 \CustomizeMathJax{\let\Chisq=\Chi}
135 \CustomizeMathJax{\newcommand{\Bet}[2]{\mb{\mathrm{Beta}}\LWRwrapparen{\mb{#1,\ #2}}}}
136 \CustomizeMathJax{\let\Beta=\Bet}
137 \CustomizeMathJax{\newcommand{\Exp}[1]{\mb{\mathrm{Exp}}\LWRwrapparen{\mb{#1}}}}
138 \CustomizeMathJax{\newcommand{\F}[2]{\mb{\mathrm{F}}\LWRwrapparen{\mb{#1,\ #2}}}}
139 \CustomizeMathJax{\newcommand{\Gam}[2]{\mb{\mathrm{Gamma}}\LWRwrapparen{\mb{#1,\ #2}}}}
140 \CustomizeMathJax{\newcommand{\IC}[1]{\mb{\mathrm{\chi^{-2}}}\LWRwrapparen{\mb{#1}}}}
141 \CustomizeMathJax{\newcommand{\IG}[2]{%
142 \mb{\mathrm{Gamma^{-1}}}\LWRwrapparen{\mb{#1,\ #2}}%
143 }}
144 \CustomizeMathJax{\newcommand{\IW}[2]{%
145 \mb{\mathrm{Wishart^{-1}}}\LWRwrapparen{\mb{#1,\ #2}}%
146 }}
147 \CustomizeMathJax{\newcommand{\Log}[2]{%
148 \mb{\mathrm{Logistic}}\LWRwrapparen{\mb{#1,\ #2}}%
149 }}
150 \CustomizeMathJax{\newcommand{\LogN}[2]{%
151 \mb{\mathrm{Log\!-\!N}}\LWRwrapparen{\mb{#1,\ #2}}%
152 }}
153 \CustomizeMathJax{\newcommand{\N}[3][]{%
154 \mb{\mathrm{N}}_{\mb{#1}}\LWRwrapparen{\mb{#2,\ #3}}%
155 }}
156 \CustomizeMathJax{\newcommand{\Par}[2]{\mb{\mathrm{Pareto}}\LWRwrapparen{\mb{#1,\ #2}}}}
157 \CustomizeMathJax{\let\Pareto=\Par}
158 \CustomizeMathJax{\newcommand{\Tsq}[2]{\mb{\mathrm{T^2}}\LWRwrapparen{\mb{#1,\ #2}}}}
159 \CustomizeMathJax{\newcommand{\U}[1]{\mb{\mathrm{U}}\LWRwrapparen{\mb{#1}}}}
160 \CustomizeMathJax{\newcommand{\W}[2]{\mb{\mathrm{Wishart}}\LWRwrapparen{\mb{#1,\ #2}}}}
161
162 \CustomizeMathJax{\renewcommand{\t}[1]{\mb{\mathrm{t}}\LWRwrapparen{\mb{#1}}}}
163
164 \CustomizeMathJax{\newcommand{\pBet}[3][x]{%
165 \IBeta{#2}{#3}%
166 #1^{#2-1}\LWRwrapparen{1-#1}^{#3-1}\I[#1]{0,\ 1}, \where #2>0 \and #3>0%
167 }}
168 \CustomizeMathJax{\newcommand{\pCau}[3][x]{%
169 {\frac{1}{#3\cpi\left\{1+\wrap{\LWRwrapparen{x-#2}/#3}^2\right\}}, \where #3>0}%
170 }}% no special case for 0,1
171 \CustomizeMathJax{\newcommand{\pChi}[2][x]{%
172 \frac{2^{-#2/2}}{\Gamma[#2/2]}#1^{#2/2-1}\e{-#1/2}%
173 \I[#1]{0,\infty}, \where #2>0%
174 }}
175 \CustomizeMathJax{\newcommand{\pExp}[2][x]{%
176 \frac{1}{#2}\e{-#1/#2}\I[#1]{0,\infty},%
177 \where #2>0%
178 }}
179 \CustomizeMathJax{\newcommand{\pGam}[3][x]{%
180 \frac{#3^{#2}}{\Gamma[#2]}#1^{#2-1}\e{-#3#1}%
181 \I[#1]{0,\infty}, \where #2>0 \and #3>0%
182 }}
183 \CustomizeMathJax{\newcommand{\pN}[3][x]{%
184 {\frac{1}{\sqrt{2\cpi \cdot #3}}\e{-\LWRwrapparen{#1-#2}^2/2 \cdot #3}}%
185 }}% no test for 0,1, must add \cdot
186 \CustomizeMathJax{\newcommand{\pPar}[3][x]{%
187 \frac{#3}{#2\LWRwrapparen{1+#1/#2}^{#3+1}}\I[#1]{0,\infty},%
188 \where #2>0 \and #3>0%
189 }}
190 \CustomizeMathJax{\newcommand{\pU}[3][x]{%
191 {\frac{1}{#3-#2}\I[#1]{#2,\ #3}, \where #2<#3}%
192 }}% no special case for 0,1
193
194 \CustomizeMathJax{\newcommand{\=}[1]{\bar{#1}}}
195 \CustomizeMathJax{\let\^\widehat}
196 \CustomizeMathJax{\let\~\widetilde}
197 \CustomizeMathJax{\newcommand{\'}[1]{\LWRwrapparen{\mb{#1}}}}
198 \CustomizeMathJax{\newcommand{\b}[1]{\bar{#1}}}
199 \CustomizeMathJax{\newcommand{\c}[1]{\mb{\mathrm{#1}}}}
200 \CustomizeMathJax{\newcommand{\d}[1]{\,\mb{\mathrm{d}{#1}}}}
201 \CustomizeMathJax{\newcommand{\.}{\mb{\ldots}}}
202 \end{warpMathJax}
203 \endinput
204 %%
205 %% End of file `lwarp-statex2.sty'.