<jupyter_start><jupyter_text>Central Limit Theorem<jupyter_code>import numpy as np
import matplotlib.pyplot as plt
##simulate 50 die rolling experiment
n_rolls = np.random.randint(1, 7, 50)
n_rolls
np.mean(n_rolls)
##simulate the exp 1000 times
n_samples = 1000

##store the mean of each sample
means = [ np.mean(np.random.randint(1, 7, 50)) for _ in range(n_samples + 1)]
means
plt.hist(means, bins=50)<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.11085450346420324, 'fraction_numerical': 0.04849884526558892, 'mean_word_length': 6.233333333333333, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '374518', 'license': 'MIT', 'n_tokens_mistral': 188, 'n_tokens_neox': 162, 'n_words': 45, 'path': 'module_9_statistics_probability/central_limit_theorem.ipynb', 'repo_name': 'wiplane/foundations-of-datascience-ml', 'size': '433'}