File:Standard Normal Distribution.svg

Uploaded by Chen-Pan Liao
Upload date 2021-11-05T08:22:07Z
MIME type image/svg+xml
Dimensions 651 × 468 px
File size 32.5 KB

Summary

Description
English: The Standard Normal Probability Distribution with shaded regions
Date
Source File:Standard_Normal_Distribution.png
Author D Wells

R code

library(ggplot2)
library(GGally)
library(extrafont)
loadfonts()
ggplot(NULL, aes(c(-4,4))) +
  geom_line(stat = "function", fun = dnorm) +
  geom_area(stat = "function", fun = dnorm, fill = scales::muted("red"), xlim=c(-1,1), alpha=1/4) +
  geom_area(stat = "function", fun = dnorm, fill = scales::muted("red"), xlim=c(-2,2), alpha=1/4) +
  geom_area(stat = "function", fun = dnorm, fill = scales::muted("red"), xlim=c(-3,3), alpha=1/4) +
  theme_minimal(base_family = "DejaVu Sans") +
  theme(axis.text.x = element_text(size = 12)) +
  scale_x_continuous(labels = paste0(-4:4, "σ"), breaks = -4:4) +
  xlab("Standard Deviations from the Mean") +
  ylab("Probability Density") +
  geom_segment(aes(x=-1, xend=1, y=dnorm(1), yend=dnorm(1)), linetype="dashed") +
  geom_segment(aes(x=-2, xend=2, y=dnorm(2), yend=dnorm(2)), linetype="dashed") +
  geom_segment(aes(x=-3, xend=3, y=dnorm(3), yend=dnorm(3)), linetype="dashed") +
  annotate("text", x = 0, y = dnorm(1)+0.015, label = "68.3%") + #pnorm(1)-pnorm(-1) %
  annotate("text", x = 0, y = dnorm(2)+0.015, label = "95.4%") +
  annotate("text", x = 0, y = dnorm(3)+0.015, label = "99.7%") +
  x11(width = 7, height = 5)

Licensing

w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.

Captions

The Standard Normal Probability Distribution with shaded regions

Items portrayed in this file

depicts

5 November 2021

image/svg+xml

Category:CC-BY-SA-4.0 Category:SVG normal distribution Category:Statistics