-
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Distributions Gallery: Add Gumbel (#514)
- Loading branch information
1 parent
e0b3ec8
commit a8d20b7
Showing
2 changed files
with
90 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
--- | ||
jupytext: | ||
text_representation: | ||
extension: .md | ||
format_name: myst | ||
kernelspec: | ||
display_name: Python 3 | ||
language: python | ||
name: python3 | ||
--- | ||
# Gumbel Distribution | ||
|
||
The Gumbel distribution, also known as the type-I Generalized Extreme Value (GEV) distribution, is a continuous probability distribution that describes the distribution of the maximum (or minimum) of a number of samples of various different random variables, particularly the exponential and normal distributions. It is characterized by two parameters: the location parameter $\mu$ and the scale parameter $\beta$. | ||
|
||
The Gumbel distribution is commonly used in the fields of hydrology, meteorology, and environmental science to model extreme events such as floods, earthquakes, and wind speeds. | ||
|
||
## Probability Density Function (PDF): | ||
|
||
```{code-cell} | ||
--- | ||
tags: [remove-input] | ||
mystnb: | ||
image: | ||
alt: Gumbel Distribution PDF | ||
--- | ||
from preliz import Gumbel, style | ||
style.use('preliz-doc') | ||
mus = [0., 4., -1.] | ||
betas = [1., 2., 4.] | ||
for mu, beta in zip(mus, betas): | ||
Gumbel(mu, beta).plot_pdf(support=(-10,20)) | ||
``` | ||
|
||
## Cumulative Distribution Function (CDF): | ||
|
||
```{code-cell} | ||
--- | ||
tags: [remove-input] | ||
mystnb: | ||
image: | ||
alt: Gumbel Distribution CDF | ||
--- | ||
for mu, beta in zip(mus, betas): | ||
Gumbel(mu, beta).plot_cdf(support=(-10,20)) | ||
``` | ||
|
||
## Key properties and parameters: | ||
|
||
```{eval-rst} | ||
======== ========================================== | ||
Support :math:`x \in (-\infty, \infty)` | ||
Mean :math:`\mu + \beta \gamma`, where :math:`\gamma` is the `Euler-Mascheroni constant <https://en.wikipedia.org/wiki/Euler%E2%80%93Mascheroni_constant>`_ | ||
Variance :math:`\frac{\pi^2}{6} \beta^2` | ||
======== ========================================== | ||
``` | ||
|
||
**Probability Density Function (PDF):** | ||
|
||
$$ | ||
f(x|\mu, \beta) = \frac{1}{\beta} e^{-(z + e^{-z})} | ||
$$ | ||
|
||
where $z = \frac{x - \mu}{\beta}$. | ||
|
||
**Cumulative Distribution Function (CDF):** | ||
|
||
$$ | ||
F(x|\mu, \beta) = e^{-e^{-z}} | ||
$$ | ||
|
||
where $z = \frac{x - \mu}{\beta}$. | ||
|
||
```{seealso} | ||
:class: seealso | ||
**Related Distributions:** | ||
- [Weibull Distribution](weibull) - If a random variable follows a Weibull distribution, the logarithm of the random variable follows a Gumbel distribution. | ||
- [Exponential Distribution](exponential) - The maximum of a number of exponentially distributed random variables follows a Gumbel distribution and the exponential distribution is a special case of the Weibull distribution. | ||
``` | ||
|
||
|
||
## References | ||
|
||
- [Wikipedia - Gumbel Distribution](https://en.wikipedia.org/wiki/Gumbel_distribution) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters