File:Central theorem 2.svg

Original file(SVG file, nominally 409 × 328 pixels, file size: 49 KB)

Summary

Description
English: Histogram of 10,000 times of Monte Carlo simulation. In each simulation, sum of 1,000 samples are recorded. For each sample, one of {1, 2, 3} is randomly chosen.
Date
Source Own work
Author Chen-Pan Liao

R code

set.seed(1)

sum.123 <- function (N) return(sum(sample(rep(1L:3L, N))[1:N]))

x <- rep(0.0, 10000)
for (i in 1L:length(m)) x[i] <- sum.123(1000)

h <- hist(
	x,
	xlab=paste0("Sample sum"),
	ylab="Frequency",
	main="Histogram of 10,000 times simulations",
	xlim=c(1900,2100), freq = T,
	breaks=seq(1900,2100,2),
	col=gray(0.9),
	cex = 2
)
xfit <- seq(min(x),max(x),length=40)
yfit <- dnorm(xfit,mean=mean(x),sd=sd(x))
yfit <- yfit*diff(h$mids[1:2])*length(x)
lines(xfit, yfit, col="red", lwd=1) 

Licensing

I, the copyright holder of this work, hereby publish it under the following license:
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

Add a one-line explanation of what this file represents

Items portrayed in this file

depicts

15 November 2014

image/svg+xml

a81e5ca4209c498ada781826041cca40ce0c82dd

50,509 byte

328 pixel

409 pixel

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current21:27, 14 November 2014Thumbnail for version as of 21:27, 14 November 2014409 × 328 (49 KB)Chen-Pan LiaoUser created page with UploadWizard
The following pages on the English Wikipedia use this file (pages on other projects are not listed):

Metadata