https://github.com/priyanshgoantiya/confidence-interval-visualization
Confidence Interval Simulation
https://github.com/priyanshgoantiya/confidence-interval-visualization
matplotlib numpy plotly seaborn
Last synced: 3 months ago
JSON representation
Confidence Interval Simulation
- Host: GitHub
- URL: https://github.com/priyanshgoantiya/confidence-interval-visualization
- Owner: priyanshgoantiya
- License: mit
- Created: 2025-04-10T08:41:40.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-04-10T08:45:27.000Z (over 1 year ago)
- Last Synced: 2025-06-04T00:30:31.304Z (about 1 year ago)
- Topics: matplotlib, numpy, plotly, seaborn
- Language: Python
- Homepage: https://vqpmrhmqzpu6y5twsbinnm.streamlit.app/
- Size: 7.81 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# confidence-interval-viz
Deployed-https://vqpmrhmqzpu6y5twsbinnm.streamlit.app/
## π§ͺ Confidence Interval Simulation
This interactive simulation helps visualize how different types of confidence intervals behave over multiple random samples from a normal distribution.
You can explore:
- **Z-distribution using population standard deviation (Ο)** β when population standard deviation is known.
- **Z-distribution using sample standard deviation (s)** β less common, but for comparison.
- **t-distribution using sample standard deviation (s)** β used when population standard deviation is unknown and sample size is small.
### π How it works:
- We simulate repeated sampling from a normal distribution.
- For each sample, we compute a confidence interval for the mean.
- If the interval captures the **true population mean**, itβs shown in **blue**; otherwise in **orange**.
- The red horizontal line represents the **true population mean**.
This tool demonstrates how often confidence intervals actually capture the population mean depending on:
- **Sample size**
- **Confidence level**
- **Distribution used (Z vs. T)**
Use the sliders in the sidebar to tweak parameters and understand how uncertainty and variability influence confidence intervals.