Skip to content

Commit 39bf5b6

Browse files
author
Bob Carpenter
authored
Merge pull request #123 from stan-dev/bugfix/121-non-negative-distributions
Move content of the non-negative distributions chapter to other chapters
2 parents 2a29127 + 3a45b9a commit 39bf5b6

15 files changed

+138
-151
lines changed

src/functions-reference/_bookdown.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,10 @@ rmd_files: [
2222
"continuous_distributions.Rmd",
2323
"unbounded_continuous_distributions.Rmd",
2424
"positive_continuous_distributions.Rmd",
25-
"non-negative_continuous_distributions.Rmd",
26-
"positive_lower-bounded_probabilities.Rmd",
25+
"positive_lower-bounded_distributions.Rmd",
2726
"continuous_distributions_on_[0_1].Rmd",
2827
"circular_distributions.Rmd",
29-
"bounded_continuous_probabilities.Rmd",
28+
"bounded_continuous_distributions.Rmd",
3029
"distributions_over_unbounded_vectors.Rmd",
3130
"simplex_distributions.Rmd",
3231
"correlation_matrix_distributions.Rmd",

src/functions-reference/binary_distributions.Rmd

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ If $\theta \in [0,1]$, then for $y \in \{0,1\}$, \[
2424

2525
`y ~ ` **`bernoulli`**`(theta)`
2626

27-
Increment target log probability density with `bernoulli_lpmf( y | theta)`
27+
Increment target log probability density with `bernoulli_lpmf(y | theta)`
2828
dropping constant additive terms.
2929
<!-- real; bernoulli; ~; -->
3030
\index{{\tt \bfseries bernoulli }!sampling statement|hyperpage}
@@ -87,7 +87,7 @@ If $\alpha \in \mathbb{R}$, then for $y \in \{0,1\}$, \[
8787

8888
`y ~ ` **`bernoulli_logit`**`(alpha)`
8989

90-
Increment target log probability density with `bernoulli_logit_lpmf( y | alpha)`
90+
Increment target log probability density with `bernoulli_logit_lpmf(y | alpha)`
9191
dropping constant additive terms.
9292
<!-- real; bernoulli_logit; ~; -->
9393
\index{{\tt \bfseries bernoulli\_logit }!sampling statement|hyperpage}
@@ -135,7 +135,7 @@ n}\text{Bernoulli}(y_i~|~\text{logit}^{-1}(\alpha_i + x_i\cdot
135135

136136
`y ~ ` **`bernoulli_logit_glm`**`(x, alpha, beta)`
137137

138-
Increment target log probability density with `bernoulli_logit_glm_lpmf( y | x, alpha, beta)`
138+
Increment target log probability density with `bernoulli_logit_glm_lpmf(y | x, alpha, beta)`
139139
dropping constant additive terms.
140140
<!-- real; bernoulli_logit_glm; ~; -->
141141
\index{{\tt \bfseries bernoulli\_logit\_glm }!sampling statement|hyperpage}

src/functions-reference/bounded_continuous_probabilities.Rmd renamed to src/functions-reference/bounded_continuous_distributions.Rmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Bounded Continuous Probabilities
1+
# Bounded Continuous Distributions
22

33
The bounded continuous probabilities have support on a finite interval
44
of real numbers.
@@ -21,7 +21,7 @@ $y \in [\alpha,\beta]$, \[ \text{Uniform}(y|\alpha,\beta) =
2121

2222
`y ~ ` **`uniform`**`(alpha, beta)`
2323

24-
Increment target log probability density with `uniform_lpdf( y | alpha, beta)`
24+
Increment target log probability density with `uniform_lpdf(y | alpha, beta)`
2525
dropping constant additive terms.
2626
<!-- real; uniform ~; -->
2727
\index{{\tt \bfseries uniform }!sampling statement|hyperpage}

src/functions-reference/bounded_discrete_distributions.Rmd

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ Suppose $N \in \mathbb{N}$ and $\theta \in [0,1]$, and $n \in
3838

3939
`n ~ ` **`binomial`**`(N, theta)`
4040

41-
Increment target log probability density with `binomial_lpmf( n | N, theta)`
41+
Increment target log probability density with `binomial_lpmf(n | N, theta)`
4242
dropping constant additive terms.
4343
<!-- real ; binomial ~; -->
4444
\index{{\tt \bfseries binomial }!sampling statement|hyperpage}
@@ -115,7 +115,7 @@ n}{\text{logit}^{-1}(\alpha)} \]
115115

116116
`n ~ ` **`binomial_logit`**`(N, alpha)`
117117

118-
Increment target log probability density with `binomial_logit_lpmf( n | N, alpha)`
118+
Increment target log probability density with `binomial_logit_lpmf(n | N, alpha)`
119119
dropping constant additive terms.
120120
<!-- real; binomial_logit ~; -->
121121
\index{{\tt \bfseries binomial\_logit }!sampling statement|hyperpage}
@@ -145,7 +145,7 @@ If $N \in \mathbb{N}$, $\alpha \in \mathbb{R}^+$, and $\beta \in
145145

146146
`n ~ ` **`beta_binomial`**`(N, alpha, beta)`
147147

148-
Increment target log probability density with `beta_binomial_lpmf( n | N, alpha, beta)`
148+
Increment target log probability density with `beta_binomial_lpmf(n | N, alpha, beta)`
149149
dropping constant additive terms.
150150
<!-- real; beta_binomial ~; -->
151151
\index{{\tt \bfseries beta\_binomial }!sampling statement|hyperpage}
@@ -207,7 +207,7 @@ If $a \in \mathbb{N}$, $b \in \mathbb{N}$, and $N \in
207207

208208
`n ~ ` **`hypergeometric`**`(N, a, b)`
209209

210-
Increment target log probability density with `hypergeometric_lpmf( n | N, a, b)`
210+
Increment target log probability density with `hypergeometric_lpmf(n | N, a, b)`
211211
dropping constant additive terms.
212212
<!-- real; hypergeometric ~; -->
213213
\index{{\tt \bfseries hypergeometric }!sampling statement|hyperpage}
@@ -245,7 +245,7 @@ distribution, \[ \text{CategoricalLogit}(y~|~\beta) =
245245

246246
`y ~ ` **`categorical`**`(theta)`
247247

248-
Increment target log probability density with `categorical_lpmf( y | theta)`
248+
Increment target log probability density with `categorical_lpmf(y | theta)`
249249
dropping constant additive terms.
250250
<!-- real; categorical ~; -->
251251
\index{{\tt \bfseries categorical }!sampling statement|hyperpage}
@@ -254,7 +254,7 @@ dropping constant additive terms.
254254

255255
`y ~ ` **`categorical_logit`**`(beta)`
256256

257-
Increment target log probability density with `categorical_logit_lpmf( y | beta)`
257+
Increment target log probability density with `categorical_logit_lpmf(y | beta)`
258258
dropping constant additive terms.
259259
<!-- real; categorical_logit ~; -->
260260
\index{{\tt \bfseries categorical\_logit }!sampling statement|hyperpage}
@@ -318,7 +318,7 @@ $\text{logit}^{-1}(\infty) = 1$.
318318

319319
`k ~ ` **`ordered_logistic`**`(eta, c)`
320320

321-
Increment target log probability density with `ordered_logistic_lpmf( k | eta, c)`
321+
Increment target log probability density with `ordered_logistic_lpmf(k | eta, c)`
322322
dropping constant additive terms.
323323
<!-- real; ordered_logistic ~; -->
324324
\index{{\tt \bfseries ordered\_logistic }!sampling statement|hyperpage}
@@ -360,7 +360,7 @@ $\Phi(\infty) = 1$.
360360

361361
`k ~ ` **`ordered_probit`**`(eta, c)`
362362

363-
Increment target log probability density with `ordered_probit_lpmf( k | eta, c)`
363+
Increment target log probability density with `ordered_probit_lpmf(k | eta, c)`
364364
dropping constant additive terms.
365365
<!-- real; ordered_probit ~; -->
366366
\index{{\tt \bfseries ordered\_probit }!sampling statement|hyperpage}

src/functions-reference/circular_distributions.Rmd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ of the values of $y$ or $\mu$).
3939

4040
`y ~ ` **`von_mises`**`(mu, kappa)`
4141

42-
Increment target log probability density with `von_mises_lpdf( y | mu, kappa)`
42+
Increment target log probability density with `von_mises_lpdf(y | mu, kappa)`
4343
dropping constant additive terms.
4444
<!-- real; von_mises ~; -->
4545
\index{{\tt \bfseries von\_mises }!sampling statement|hyperpage}

src/functions-reference/continuous_distributions_on_[0_1].Rmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ distribution requires strictly positive parameters, $\alpha, \beta >
2929

3030
`theta ~ ` **`beta`**`(alpha, beta)`
3131

32-
Increment target log probability density with `beta_lpdf( theta | alpha, beta)`
32+
Increment target log probability density with `beta_lpdf(theta | alpha, beta)`
3333
dropping constant additive terms.
3434
<!-- real; beta ~; -->
3535
\index{{\tt \bfseries beta }!sampling statement|hyperpage}
@@ -96,7 +96,7 @@ parameter, $\kappa > 0$.
9696

9797
`theta ~ ` **`beta_proportion`**`(mu, kappa)`
9898

99-
Increment target log probability density with `beta_proportion_lpdf( theta | mu, kappa)`
99+
Increment target log probability density with `beta_proportion_lpdf(theta | mu, kappa)`
100100
dropping constant additive terms.
101101
<!-- real; beta_proportion ~; -->
102102
\index{{\tt \bfseries beta\_proportion }!sampling statement|hyperpage}

src/functions-reference/correlation_matrix_distributions.Rmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ practice.
5959

6060
`y ~ ` **`lkj_corr`**`(eta)`
6161

62-
Increment target log probability density with `lkj_corr_lpdf( y | eta)`
62+
Increment target log probability density with `lkj_corr_lpdf(y | eta)`
6363
dropping constant additive terms.
6464
<!-- real; lkj_corr ~; -->
6565
\index{{\tt \bfseries lkj\_corr }!sampling statement|hyperpage}
@@ -127,7 +127,7 @@ unit Euclidean length.
127127

128128
`L ~ ` **`lkj_corr_cholesky`**`(eta)`
129129

130-
Increment target log probability density with `lkj_corr_cholesky_lpdf( L | eta)`
130+
Increment target log probability density with `lkj_corr_cholesky_lpdf(L | eta)`
131131
dropping constant additive terms.
132132
<!-- real; lkj_corr_cholesky ~; -->
133133
\index{{\tt \bfseries lkj\_corr\_cholesky }!sampling statement|hyperpage}

src/functions-reference/covariance_matrix_distributions.Rmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ Gamma function, \[ \Gamma_K(x) = \frac{1}{\pi^{K(K-1)/4}} \
2929

3030
`W ~ ` **`wishart`**`(nu, Sigma)`
3131

32-
Increment target log probability density with `wishart_lpdf( W | nu, Sigma)`
32+
Increment target log probability density with `wishart_lpdf(W | nu, Sigma)`
3333
dropping constant additive terms.
3434
<!-- real; wishart ~; -->
3535
\index{{\tt \bfseries wishart }!sampling statement|hyperpage}
@@ -68,7 +68,7 @@ for symmetric and positive-definite $W \in \mathbb{R}^{K \times K}$,
6868

6969
`W ~ ` **`inv_wishart`**`(nu, Sigma)`
7070

71-
Increment target log probability density with `inv_wishart_lpdf( W | nu, Sigma)`
71+
Increment target log probability density with `inv_wishart_lpdf(W | nu, Sigma)`
7272
dropping constant additive terms.
7373
<!-- real; inv_wishart ~; -->
7474
\index{{\tt \bfseries inv\_wishart }!sampling statement|hyperpage}

src/functions-reference/distributions_over_unbounded_vectors.Rmd

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ $\Sigma$.
3131

3232
`y ~ ` **`multi_normal`**`(mu, Sigma)`
3333

34-
Increment target log probability density with `multi_normal_lpdf( y | mu, Sigma)`
34+
Increment target log probability density with `multi_normal_lpdf(y | mu, Sigma)`
3535
dropping constant additive terms.
3636
<!-- real; multi_normal ~; -->
3737
\index{{\tt \bfseries multi\_normal }!sampling statement|hyperpage}
@@ -121,7 +121,7 @@ for $y \in \mathbb{R}^K$, \[ \text{MultiNormalPrecision}(y|\mu,\Omega)
121121

122122
`y ~ ` **`multi_normal_prec`**`(mu, Omega)`
123123

124-
Increment target log probability density with `multi_normal_prec_lpdf( y | mu, Omega)`
124+
Increment target log probability density with `multi_normal_prec_lpdf(y | mu, Omega)`
125125
dropping constant additive terms.
126126
<!-- real; multi_normal_prec ~; -->
127127
\index{{\tt \bfseries multi\_normal\_prec }!sampling statement|hyperpage}
@@ -174,7 +174,7 @@ probability functions will raise errors.
174174

175175
`y ~ ` **`multi_normal_cholesky`**`(mu, L)`
176176

177-
Increment target log probability density with `multi_normal_cholesky_lpdf( y | mu, L)`
177+
Increment target log probability density with `multi_normal_cholesky_lpdf(y | mu, L)`
178178
dropping constant additive terms.
179179
<!-- real; multi_normal_cholesky ~; -->
180180
\index{{\tt \bfseries multi\_normal\_cholesky }!sampling statement|hyperpage}
@@ -263,7 +263,7 @@ function does not take into account the mean prediction.
263263

264264
`y ~ ` **`multi_gp`**`(Sigma, w)`
265265

266-
Increment target log probability density with `multi_gp_lpdf( y | Sigma, w)`
266+
Increment target log probability density with `multi_gp_lpdf(y | Sigma, w)`
267267
dropping constant additive terms.
268268
<!-- real; multi_gp ~; -->
269269
\index{{\tt \bfseries multi\_gp }!sampling statement|hyperpage}
@@ -299,7 +299,7 @@ account the mean prediction.
299299

300300
`y ~ ` **`multi_gp_cholesky`**`(L, w)`
301301

302-
Increment target log probability density with `multi_gp_cholesky_lpdf( y | L, w)`
302+
Increment target log probability density with `multi_gp_cholesky_lpdf(y | L, w)`
303303
dropping constant additive terms.
304304
<!-- real; multi_gp_cholesky ~; -->
305305
\index{{\tt \bfseries multi\_gp\_cholesky }!sampling statement|hyperpage}
@@ -332,7 +332,7 @@ K)/2\right)} {\Gamma(\nu/2)} \ \frac{1}{\sqrt{\left| \Sigma
332332

333333
`y ~ ` **`multi_student_t`**`(nu, mu, Sigma)`
334334

335-
Increment target log probability density with `multi_student_t_lpdf( y | nu, mu, Sigma)`
335+
Increment target log probability density with `multi_student_t_lpdf(y | nu, mu, Sigma)`
336336
dropping constant additive terms.
337337
<!-- real; multi_student_t ~; -->
338338
\index{{\tt \bfseries multi\_student\_t }!sampling statement|hyperpage}
@@ -420,7 +420,7 @@ processes observations and avoids a matrix inversions can be used
420420

421421
`y ~ ` **`gaussian_dlm_obs`**`(F, G, V, W, m0, C0)`
422422

423-
Increment target log probability density with `gaussian_dlm_obs_lpdf( y | F, G, V, W, m0, C0)`
423+
Increment target log probability density with `gaussian_dlm_obs_lpdf(y | F, G, V, W, m0, C0)`
424424
dropping constant additive terms.
425425
<!-- real; gaussian_dlm_obs ~; -->
426426
\index{{\tt \bfseries gaussian\_dlm\_obs }!sampling statement|hyperpage}

src/functions-reference/multivariate_discrete_distributions.Rmd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ multinomial coefficient is defined by \[ \binom{N}{y_1,\ldots,y_k} =
2424

2525
`y ~ ` **`multinomial`**`(theta)`
2626

27-
Increment target log probability density with `multinomial_lpmf( y | theta)`
27+
Increment target log probability density with `multinomial_lpmf(y | theta)`
2828
dropping constant additive terms.
2929
<!-- real; multinomial ~; -->
3030
\index{{\tt \bfseries multinomial }!sampling statement|hyperpage}

0 commit comments

Comments
 (0)