Normal Distribution

Instance of: probability distribution

AKA: Normal; Gaussian distribution; Standard normal; bell curve; \(\varphi(x)\); \(X \sim \mathrm{N}()\); \(\Phi(x)\); normal deviate

Distinct from:

English: The normal distribution is a symmetric bell shaped distribution that has several important mathematical properties: it the distribution with maximum entropy of all possible distributions with a specified mean and variance; it is the distribution that a binomial distribution tends toward as the sample goes to infinity (infinite coin flips); and it is the distribution that the mean of samples from any other distribution with finite mean and variance will tend towards (central limit theorem). Because of its centrality and generality, many real world natural phenomenon will tend to be normally distributed.

Some related ideas * The mean of any set of variates with finite mean and variance tends to be normally distributed, Central Limit Theorem. * The sum or subtraction of two normally distributed variables is also normally distributed. * The ratio of two normally distributed variables is Cauchy distributed.

Formalization:

Some intuition for the formalization of the pdf

  • It approximates the pdf of a Binomial Distribution with the same mean and variance as N goes to infinity (Tushev 2021).

  • The denominator \(\frac{1}{\sigma\sqrt(2\pi)}\) can be thought of as a constant for normalizing/scaling the distribution taking into account the variance and making sure it sums to 1.

  • The numerator \(\mathrm{e}^{-\frac{1}{2}(\frac{x-\mu}{\sigma})^2}\) can be thought of as several cascading functions that together pound the curve into the desired shaped

  • Euler’s number appears \(e^A\) as an arbitrary convenient base and could be replaced with any other positive constant with some modification(Tushev 2021)

Standard normal distribution with mean zero and standard deviation one \[ f(x)=\frac{\mathrm{e}^{-\frac{1}{2}(x)^2}}{\sqrt{2\pi}} \]

Where \(\mathrm{e}\) is Euler’s number.
x is event.
The denominator \(\sqrt{2\pi}\) acts to scale.

x=0
numerator=exp(-1*0.5*x^2)
denominator=sqrt(2*pi)
numerator/denominator
[1] 0.3989423
dnorm(0)
[1] 0.3989423
library(ggplot2)
x=seq(-3,3,0.1)
ggplot() + geom_point(aes(x=x,y=dnorm(x=x,mean = 0, sd = 1)))

Including \(\mu\) and \(\sigma\) allow us to shift and stretch the distribution \[ f(x)=\frac{\mathrm{e}^{-\frac{1}{2}(\frac{x-\mu}{\sigma})^2}}{\sigma\sqrt{2\pi}} \]

library(ggplot2)
x=seq(-3,3,0.1)
ggplot() + geom_point(aes(x=x,y=dnorm(x=x,mean = 1, sd = 1)))

ggplot() + geom_point(aes(x=x,y=dnorm(x=x,mean = 0, sd = 2)))

Cites: Wikipedia ; Wikidata ; Wolfram

A Simple Intuition Behind The Normal Distribution Equation(Tushev 2021)

The Normal Distribution as a Limit of Binomial Distributions(Sarty 2022)

Fisher, R. A. “Statistical Methods for Research Workers, 13e.” London: Oliver and Loyd, Ltd, 1925, 99–101.

A variate is said to be normally distributed when it takes all values from -[infinity], to +[infinity] , with frequencies given by a definite mathematical law, namely, that the logarithm of the frequency at any distance x from the centre of the distribution is less than the logarithm of the frequency at the centre by a quantity proportional to x2. The distribution is therefore symmetrical, with the greatest frequency at the centre; although the variation is unlimited, the frequency falls off to exceedingly small values at any considerable distance from the centre, since a large negative logarithm corresponds to a very small number.

Code

Examples:

Examples:

library(DBI)
# Create an ephemeral in-memory RSQLite database
#con <- dbConnect(RSQLite::SQLite(), dbname = ":memory:")
#dbListTables(con)
#dbWriteTable(con, "mtcars", mtcars)
#dbListTables(con)

#Configuration failed because libpq was not found. Try installing:
#* deb: libpq-dev libssl-dev (Debian, Ubuntu, etc)
#install.packages('RPostgres')
#remotes::install_github("r-dbi/RPostgres")
#Took forever because my file permissions were broken
#pg_lsclusters
require(RPostgres)
Loading required package: RPostgres
# Connect to the default postgres database
#I had to follow these instructions and create both a username and database that matched my ubuntu name
#https://www.digitalocean.com/community/tutorials/how-to-install-postgresql-on-ubuntu-20-04-quickstart
con <- dbConnect(RPostgres::Postgres())
import torch

0.1 Bayesian

English: Formalization:

\[ \]

Cites:

Code

References

Sarty, Gordon E. 2022. “5.2 **The Normal Distribution as a Limit of Binomial Distributions.” Introduction to Applied Statistics for Psychology Students, March.
Tushev, Miroslav. 2021. “A Simple Intuition Behind The Normal Distribution Equation.” Medium.