StatsCalculators.com

Normal Distribution

Created:November 22, 2024
Last Updated:March 29, 2025

This calculator helps you compute the probabilities of a normal distribution given the mean and standard deviation. You can find the probability of a value being less than, greater than, or between certain values given the mean and standard deviation of the normal distribution . The distribution chart shows the probability density function (PDF) and cumulative density function (CDF) of the normal distribution.

Calculator

Parameters

Important:If you have variance (σ² = 25), enter standard deviation (σ = 5)

Tip:P(X≤x) = P(X<x) since the probability of any exact value is zero.

Interactive Distribution Chart

Click Calculate to view the distribution chart

Related Calculators

Learn More

Normal Distribution

Definition: The normal distribution, also known as the Gaussian distribution, is a continuous probability distribution that is symmetric about its mean and follows a characteristic "bell-shaped" curve.

Formula:The probability density function (PDF) and cumulative density function (CDF) are given by:f(x)=1σ2πe(xμ)22σ2f(x) = \frac{1}{\sigma\sqrt{2\pi}} e^{-\frac{(x-\mu)^2}{2\sigma^2}}F(x)=P(Xx)=Φ(xμσ)F(x) = P(X \leq x) = \Phi \left({\frac {x-\mu }{\sigma }}\right)

Where:

  • μ\mu is the mean (location parameter)
  • σ\sigma is the standard deviation (scale parameter)
  • σ2\sigma^2 is the variance
Also,P(a<Xb)=Φ(bμσ)Φ(aμσ)P(a < X \leq b) = \Phi \left({\frac {b-\mu }{\sigma }}\right) - \Phi \left({\frac {a-\mu }{\sigma }}\right)
Example: Let XN(5,4)X \sim N(-5, 4), find P(7<X<3)P(-7 < X < -3). P(7<X<3)=Φ(3+52)Φ(7+52)=Φ(1)Φ(1)=0.6827P(-7 < X < -3) = \Phi \left(\frac{-3+5}{2}\right) - \Phi \left(\frac{-7+5}{2}\right) = \Phi(1) - \Phi(-1) = 0.6827

Properties

  • Symmetric about the mean
  • Bell-shaped curve
  • Mean, median, and mode are all equal
  • 68-95-99.7 rule:
    • 68% of data falls within 1 standard deviation of the mean
    • 95% of data falls within 2 standard deviations
    • 99.7% of data falls within 3 standard deviations

Z-Scores

Definition: A z-score represents how many standard deviations away from the mean a data point is.

z=xμσz = \frac{x - \mu}{\sigma}

Where:

  • xx is the data point
  • μ\mu is the mean
  • σ\sigma is the standard deviation

Explore the Normal Distribution

Adjust the mean and standard deviation to see how they affect the shape of the normal curve.

Observe how:

  • The mean shifts the center of the curve left or right
  • The standard deviation makes the curve wider or narrower
  • The total area under the curve always remains the same

Ready for More?

Compare Multiple Distributions

Visualize several normal curves simultaneously to compare different parameters.

Bell Curve Generator

Analyze Your Data

Upload your dataset and compare it against theoretical normal distributions.

Data Comparison

How to Calculate Normal Distribution in R

R
library(tidyverse)

# P(X < 1) - P(X < -1)
P_between <- pnorm(1) - pnorm(-1)
print(p_between) # 0.6826895

# X ~ N(-5, 4)
# P(-7 < X < -3)
p_between <- pnorm(-3, mean = -5, sd = 2) - pnorm(-7, mean = -5, sd = 2)
print(p_between) # 0.6826895

# plot the standard normal distribution
x <- seq(-3, 3, length.out = 1000)
pdf <- dnorm(x)
df <- tibble(x = x, pdf = pdf)

ggplot(df, aes(x = x, y = pdf)) +
  geom_line(color = "blue") +
  geom_area(data = subset(df, x >= -1 & x <= 1), aes(x = x, y = pdf), fill = "blue", alpha = 0.2) +
  labs(title = "Standard Normal Distribution",
       x = "x",
       y = "Probability Density") +
  annotate("text", x = 1, y = 0.3, label = str_glue("P(-1 < X < 1) = {round(P_between, 4)}"), hjust = 0) +
  theme_minimal()

How to Calculate Normal Distribution in Python

Python
import pandas as pd
import numpy as np
import scipy.stats as stats
import matplotlib.pyplot as plt

# P(X < 1) - P(X < -1)
p_between = stats.norm.cdf(1) - stats.norm.cdf(-1)
print(p_between)

# X ~ N(-5, 4)
# P(-7 < X < -3)
p_between = stats.norm.cdf(-3, loc=-5, scale=2) - stats.norm.cdf(-7, loc=-5, scale=2)
print(p_between)

# Plot the standard normal distribution
x = np.linspace(-3, 3, 1000)
pdf = stats.norm.pdf(x)

# Create a pandas DataFrame
df = pd.DataFrame({'x': x, 'pdf': pdf})

# Plotting
plt.plot(df['x'], df['pdf'], color="blue")
plt.fill_between(df['x'], df['pdf'], where=(df['x'] >= -1) & (df['x'] <= 1), color="blue", alpha=0.2)
plt.title("Standard Normal Distribution")
plt.xlabel("x")
plt.ylabel("Probability Density")
plt.annotate(f"P(-1 < X < 1) = {round(p_between, 4)}", xy=(1, 0.3), ha='left')
plt.grid(True)
plt.show()