https://github.com/satvikpraveen/matplotlibmasterpro
π· MatplotlibMasterPro is a complete, portfolio-ready project to master data visualization using matplotlib. Includes 16 notebooks, real datasets, exportable plots, custom themes, Streamlit dashboard, and Docker support. Ideal for learners and data professionals.
https://github.com/satvikpraveen/matplotlibmasterpro
charts custom-plots dashboarding data-analysis data-science data-visualization educational-project interactive-visualizations jupyter-notebook matplotlib notebooks open-source plotting portfolio-project python python-utilities reproducible-research subplots time-series-analysis visualization-tools
Last synced: 29 days ago
JSON representation
π· MatplotlibMasterPro is a complete, portfolio-ready project to master data visualization using matplotlib. Includes 16 notebooks, real datasets, exportable plots, custom themes, Streamlit dashboard, and Docker support. Ideal for learners and data professionals.
- Host: GitHub
- URL: https://github.com/satvikpraveen/matplotlibmasterpro
- Owner: SatvikPraveen
- License: gpl-3.0
- Created: 2025-07-25T00:00:59.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2026-03-08T21:34:41.000Z (3 months ago)
- Last Synced: 2026-03-09T02:22:15.153Z (3 months ago)
- Topics: charts, custom-plots, dashboarding, data-analysis, data-science, data-visualization, educational-project, interactive-visualizations, jupyter-notebook, matplotlib, notebooks, open-source, plotting, portfolio-project, python, python-utilities, reproducible-research, subplots, time-series-analysis, visualization-tools
- Language: Jupyter Notebook
- Homepage:
- Size: 6.42 MB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# π MatplotlibMasterPro
[](https://www.gnu.org/licenses/gpl-3.0)
[](https://www.python.org/)
[](https://jupyter.org/)
[](https://matplotlib.org/)
[](#)
[](#)
[](#)
[](#)
[](#)
[](#)
[](#)
---
## π§ Project Overview
**MatplotlibMasterPro** is a complete, portfolio-grade project designed to **master data visualization using `matplotlib.pyplot`**.
Itβs structured to serve both as a:
- π **Self-paced learning notebook series**
- πΌ **Professional showcase project**
Whether youβre revisiting fundamentals or creating complex dashboards β this project brings it all together in one place.
---
## π Project Structure
```bash
MatplotlibMasterPro/
βββ notebooks/ # π Step-by-step concept notebooks (23 total)
βββ scripts/ # π Production-ready Python scripts
βββ examples/ # π Quick copy-paste examples
βββ tests/ # π§ͺ Unit tests for utilities
βββ utils/ # π οΈ Plotting utility functions
β βββ plot_utils.py # Line, bar, scatter, histogram helpers
β βββ theme_utils.py # Publication-ready themes
βββ docs/ # π Documentation files
β βββ SETUP.md # Environment setup guide
β βββ TROUBLESHOOTING.md # Common issues and solutions
β βββ RESOURCES.md # Learning materials
β βββ RECOMMENDATIONS.md # Project roadmap
β βββ CONTRIBUTING.md # Contribution guidelines
β βββ CODE_OF_CONDUCT.md # Community standards
βββ cheatsheets/ # π Quick-reference syntax guides
βββ datasets/ # π Sample CSV datasets
βββ exports/ # πΎ Generated plots and dashboards
βββ streamlit_app.py # π Streamlit dashboard viewer
βββ activate.sh # β‘ Quick venv activation script
βββ requirements.txt # π¦ Minimal dependencies
βββ requirements_dev.txt # π§ Full dev environment
βββ Dockerfile # π³ Dockerized Jupyter environment
```
---
## π Notebooks Roadmap
| Notebook | Description |
| ---------------------------- | --------------------------------------------------- |
| `01_line_plot.ipynb` | Basics of `plot()`, labels, legend |
| `02_bar_scatter.ipynb` | Bar charts and scatter plots |
| `03_histogram_pie.ipynb` | Distributions and pie charts |
| `04_subplots_axes.ipynb` | Subplotting and axes control |
| `05_customization.ipynb` | Colors, linestyles, themes |
| `06_advanced_plots.ipynb` | Log plots, heatmaps, fill areas |
| `07_annotations.ipynb` | Labels, arrows, text, highlights |
| `08_images_and_grids.ipynb` | `imshow`, `matshow`, grids |
| `09_interactive.ipynb` | Widgets, sliders, `%matplotlib notebook` |
| `10_export_style.ipynb` | Save figures, DPI, formats, themes |
| `11_animation.ipynb` | Animated plots, FuncAnimation, saving MP4/GIF |
| `12_stats_distribution.ipynb`| Statistical distributions and plots |
| `13_comparative_plots.ipynb` | Grouped bars, stacked areas, side-by-side views |
| `14_colormaps_themes.ipynb` | Colormaps, gradients, diverging schemes |
| `15_timeseries.ipynb` | Time-series: trends, seasonal cycles |
| `16_dashboards.ipynb` | Multi-panel dashboards using `subplots`, `gridspec` |
| `17_3d_plots.ipynb` | 3D scatter, surface, wireframe plots |
| `18_statistical_plots.ipynb` | Box plots, violin plots, swarm plots |
| `19_error_visualization.ipynb`| Error bars, confidence intervals, fill between |
| `20_contour_plots.ipynb` | Contour, contourf, filled contours, heatmaps |
| `21_polar_plots.ipynb` | Polar coordinates, radial plots, circular data |
| `22_composite_plots.ipynb` | Layered plots, twin axes, broken axes |
| `23_inset_zoom.ipynb` | Inset plots, zoomed views, anchored boxes |
---
## β¨ Advanced Visualization Features
This project covers **comprehensive matplotlib capabilities** including:
- οΏ½ **23 Interactive Notebooks** β From basics to advanced techniques
- π **5 Production Scripts** β Real-world automation examples
- π **5 Quick Examples** β Copy-paste ready templates
- π§ͺ **80+ Unit Tests** β Professional testing practices
- π¦ **3D Visualizations** β Surface plots, wireframes, 3D scatter plots
- π **Statistical Analysis** β Box plots, violin plots, distribution comparisons
- π **Error Visualization** β Error bars, confidence intervals, uncertainty quantification
- πΊοΈ **Field Representation** β Contour plots, filled contours, heatmaps
- π΅ **Polar & Circular Data** β Radar charts, rose plots, wind roses
- π **Multi-Scale Plots** β Twin axes, layered visualizations, broken axes
- π **Detail Views** β Inset plots, zoomed views, magnified regions
- π¨ **8 Publication Themes** β IEEE, academic, colorblind-friendly palettes
- π¬ **Animations** β FuncAnimation, timeline effects, dynamic visualizations
- π **Complex Layouts** β GridSpec, nested subplots, multi-panel dashboards
---
## πΈ Sample Visualizations
Here are two dashboards from the project:

_Advanced layout using `GridSpec` for flexible placement_

_Subplots with shared axes and tight layout for cleaner visuals_
## ποΈ Animated Visualizations
Here are animated visualizations exported from the project:
- π¬ [`product_revenue_bars.mp4`](exports/product_revenue_bars.mp4)
_Animated bar chart showing revenue distribution by product_
- π [`revenue_growth.mp4`](exports/revenue_growth.mp4)
_Revenue growth over time with animated line movement_
- π [`units_revenue_growth.mp4`](exports/units_revenue_growth.mp4)
_Dual-plot animation comparing units sold and revenue growth_
- π [`revenue_vs_units_scatter.mp4`](exports/revenue_vs_units_scatter.mp4)
_Dynamic scatter plot showing correlation over time_
## π§ͺ Datasets Created and Used
| Filename | Description |
| ------------------ | -------------------------------------------- |
| `sales_data.csv` | Monthly product-wise sales and revenue |
| `covid_cases.csv` | Cumulative COVID-19 cases across U.S. states |
| `stock_prices.csv` | OHLC & volume for multiple stock tickers |
| `weather_data.csv` | Daily city-level temperature and humidity |
> All datasets are generated using `pandas` and `numpy`, and stored under [`datasets/`](datasets/).
---
## π οΈ Utilities
Reusable helper functions to accelerate your matplotlib workflow:
- **[`utils/plot_utils.py`](utils/plot_utils.py)** β 20+ functions for common plots (line, bar, scatter, histogram, pie, etc.)
- **[`utils/theme_utils.py`](utils/theme_utils.py)** β 8 publication-ready themes (dark, minimal, corporate, IEEE, colorblind-friendly, etc.)
---
## π Production Scripts
Ready-to-run Python scripts in [`scripts/`](scripts/):
| Script | Description | Command |
|--------|-------------|---------|
| **generate_dashboard.py** | Multi-panel sales dashboard | `python scripts/generate_dashboard.py` |
| **generate_3d_plots.py** | Batch 3D visualizations | `python scripts/generate_3d_plots.py` |
| **generate_statistical_plots.py** | Box/violin plots | `python scripts/generate_statistical_plots.py` |
| **batch_export.py** | Export in PNG/PDF/SVG | `python scripts/batch_export.py` |
| **create_publication_figures.py** | IEEE/academic figures | `python scripts/create_publication_figures.py` |
**Use Cases:** Automated reporting, batch processing, production pipelines
---
## π Quick Examples
Minimal, copy-paste ready scripts in [`examples/`](examples/):
| Example | Description | Lines of Code |
|---------|-------------|---------------|
| **quick_start.py** | Your first plot | ~10 |
| **publication_figure.py** | Academic paper-ready | ~25 |
| **batch_process.py** | Process multiple CSVs | ~30 |
| **custom_theme_example.py** | Apply themes | ~20 |
| **animation_example.py** | Simple animation | ~18 |
**Use Cases:** Learning, prototyping, templates for projects
---
## π§ͺ Testing
Professional unit tests in [`tests/`](tests/):
- **test_plot_utils.py** β Tests for plotting functions (50+ tests)
- **test_theme_utils.py** β Tests for theme utilities (30+ tests)
**Run tests:**
```bash
python -m pytest tests/ -v
```
**With coverage:**
```bash
python -m pytest tests/ --cov=utils --cov-report=html
```
---
## π§Ύ Cheatsheets
Quick-reference syntax guides available at:
- [`cheatsheets/matplotlib_cheatsheet.md`](cheatsheets/matplotlib_cheatsheet.md)
---
## π Documentation & Resources
This project includes comprehensive documentation to support your learning:
- π **[SETUP.md](docs/SETUP.md)** β Complete environment setup guide with activation instructions
- π‘ **[RECOMMENDATIONS.md](docs/RECOMMENDATIONS.md)** β Prioritized improvement suggestions and project roadmap
- π§ **[TROUBLESHOOTING.md](docs/TROUBLESHOOTING.md)** β Solutions for common matplotlib issues (backends, fonts, performance, etc.)
- π **[RESOURCES.md](docs/RESOURCES.md)** β Curated learning resources (courses, books, communities, datasets)
- π€ **[CONTRIBUTING.md](docs/CONTRIBUTING.md)** β Contribution guidelines for the project
- π **[CODE_OF_CONDUCT.md](docs/CODE_OF_CONDUCT.md)** β Community standards and behavior expectations
- π **[scripts/README.md](scripts/README.md)** β Production scripts documentation
- π **[examples/README.md](examples/README.md)** β Quick examples documentation
- π§ͺ **[tests/README.md](tests/README.md)** β Testing guide and best practices
---
## π Getting Started
### **Option 1: Virtual Environment (Recommended)**
1. **Clone the repository:**
```bash
git clone https://github.com/SatvikPraveen/MatplotlibMasterPro.git
cd MatplotlibMasterPro
```
2. **Use the quick activation script:**
```bash
source activate.sh
```
Or activate manually:
```bash
source venv/bin/activate # macOS/Linux
venv\Scripts\activate # Windows
```
3. **Launch JupyterLab:**
```bash
jupyter lab
```
4. **Or run production scripts:**
```bash
python scripts/generate_dashboard.py
python examples/quick_start.py
```
5. **Run tests (optional):**
```bash
python -m pytest tests/ -v
```
π **For detailed setup instructions, see [SETUP.md](docs/SETUP.md)**
π‘ **For improvement suggestions, see [RECOMMENDATIONS.md](docs/RECOMMENDATIONS.md)**
π§ **For troubleshooting help, see [TROUBLESHOOTING.md](docs/TROUBLESHOOTING.md)**
π **For learning resources, see [RESOURCES.md](docs/RESOURCES.md)**
### **Option 2: Docker (Isolated Environment)**
See the [Dockerized Setup](#-dockerized-setup) section below.
---
## π Streamlit App
Explore exported dashboards interactively:
```bash
streamlit run streamlit_app.py
```
Or via Docker:
```bash
docker build -t matplotlibmasterpro .
docker run -p 8501:8501 matplotlibmasterpro
```
---
## π³ Dockerized Setup
Run a fully isolated Jupyter + Streamlit environment with ease.
```bash
# Build the container
docker build -t matplotlibmasterpro .
# Launch Jupyter
docker run -p 8888:8888 matplotlibmasterpro
```
> Tokenless access enabled by default. Use `--rm -d` to run in background.
---
## π Future Enhancements
- [x] Streamlit integration for dashboard browsing
- [x] JupyterLab with Docker
- [x] Advanced 3D visualizations
- [x] Statistical plotting techniques
- [x] Publication-ready themes
- [x] Comprehensive troubleshooting guide
- [x] Curated learning resources
- [x] Production-ready Python scripts
- [x] Quick copy-paste examples
- [x] Unit tests with pytest
- [ ] PDF report export
- [ ] Pip-installable library version
- [ ] Interactive Plotly/Bokeh integrations
- [ ] Real-world case studies
- [ ] CI/CD pipeline
---
## πΌ License
This project is licensed under the [GNU General Public License v3.0](https://www.gnu.org/licenses/gpl-3.0). See the [LICENSE](./LICENSE) file for more details.
---
## π Contributing
Want to contribute?
- β
Fork the repo
- π§ Create a feature branch
- π Submit a PR with your improvements
- π Open issues for bugs or suggestions
---