File:Lawoflargenumbers.svg

Summary

Description
English: Illustration of Law of large numbers.
Date
Source Own work
Author Pred
SVG development
InfoField
 The source code of this SVG is invalid due to an error.
 This W3C-invalid vector image was created with Python.
Category:Invalid SVG created with Python#1000Lawoflargenumbers.svg

Licensing

Pred, the copyright holder of this work, hereby publishes it under the following license:
Creative Commons CC-Zero This file is made available under the Creative Commons CC0 1.0 Universal Public Domain Dedication.
The person who associated a work with this deed has dedicated the work to the public domain by waiving all of their rights to the work worldwide under copyright law, including all related and neighboring rights, to the extent allowed by law. You can copy, modify, distribute and perform the work, even for commercial purposes, all without asking permission.

Category:CC-Zero#Lawoflargenumbers.svgCategory:Self-published work

Source code

The logo of Python – general-purpose programming language
The logo of Python – general-purpose programming language
This media was created with Python (general-purpose programming language)Category:Images with Python source code
Here is a listing of the source used to create this file.

Deutsch  English  +/− The plot was produced using the following Python source code

import numpy as np
import matplotlib.pyplot as plt
import seaborn as sns
np.random.seed(0)

x = np.arange(1, 1001, 1)
samples = np.random.randint(1, 7, len(x))
averages = np.cumsum(samples)/x

plt.plot((0, 1000), (3.5, 3.5), label='Theoretical mean')
plt.plot(x, averages, label='Observed averages')

plt.title('Average dice roll by number of rolls')
plt.xlabel('Number of trials')
plt.ylabel('Average')
plt.ylim((1, 6))
plt.legend()
plt.savefig('lawoflargenumbers.svg')
Category:Probability theory
Category:CC-Zero Category:Images with Python source code Category:Invalid SVG created with Python Category:Probability theory Category:Self-published work