Metadata-Version: 2.4
Name: eda-datapilot
Version: 0.2.3
Summary: DataPilot - A powerful, automated Exploratory Data Analysis (EDA) library in Python
Author-email: Sakshi Nagare <sakshinagare2112@gmail.com>
License: MIT
License-File: LICENSE
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Scientific/Engineering :: Information Analysis
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Dist: jinja2>=3.1.0
Requires-Dist: loguru>=0.7.0
Requires-Dist: matplotlib>=3.7.0
Requires-Dist: numpy>=1.24.0
Requires-Dist: pandas>=2.0.0
Requires-Dist: plotly>=5.14.0
Requires-Dist: pydantic>=2.0.0
Requires-Dist: scikit-learn>=1.2.0
Requires-Dist: scipy>=1.10.0
Requires-Dist: seaborn>=0.12.0
Provides-Extra: dev
Requires-Dist: black>=23.0.0; extra == 'dev'
Requires-Dist: mypy>=1.3.0; extra == 'dev'
Requires-Dist: pytest-cov>=4.1.0; extra == 'dev'
Requires-Dist: pytest>=7.3.0; extra == 'dev'
Requires-Dist: ruff>=0.1.0; extra == 'dev'
Description-Content-Type: text/markdown

# 🚀 DataPilot — Automated EDA Library

[![PyPI version](https://img.shields.io/pypi/v/eda-datapilot)](https://pypi.org/project/eda-datapilot/)
[![Python](https://img.shields.io/pypi/pyversions/eda-datapilot)](https://pypi.org/project/eda-datapilot/)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

**DataPilot** is a Python library for automated Exploratory Data Analysis (EDA).  
Give it a pandas DataFrame — it gives you a beautiful, interactive HTML report with statistics, visualizations, outlier detection, data quality alerts, and ML insights.

---

## ✨ Features

- 📊 Dataset shape, memory usage, and data-type summaries
- ❓ Missing values analysis per column
- 🔢 Numerical & categorical statistics
- 🔗 Pearson, Spearman, and Kendall correlations
- 🚨 IQR and Z-score outlier detection
- ⚠️ Data-quality alerts and preprocessing recommendations
- 🤖 ML task detection, feature importance, and PCA insights
- 📄 Standalone interactive HTML reports with Plotly + Seaborn charts

---

## 📦 Installation

Install directly from PyPI:

```bash
pip install eda-datapilot
```

Upgrade to the latest version:

```bash
pip install --upgrade eda-datapilot
```

> **Requirements:** Python 3.10 or newer

---

## 🖥️ Usage in Jupyter Notebook

### Step 1 — Install

```python
!pip install --upgrade eda-datapilot
```

### Step 2 — Run EDA on your CSV

```python
import pandas as pd
import datapilot
from IPython.display import IFrame

# Verify version
print("DataPilot version:", datapilot.__version__)

# Change to your CSV file path
df = pd.read_csv("your_file.csv")

print(f"Loaded: {df.shape[0]} rows × {df.shape[1]} columns")
print(f"Columns: {list(df.columns)}")

# Set your target column or keep None
TARGET = None   # e.g. TARGET = "Price" or TARGET = "diagnosis"

# Run full EDA
report = datapilot.analyze(df, target=TARGET)

# Save & display inline in Jupyter
report.to_html("My_EDA_Report.html")
IFrame("My_EDA_Report.html", width="100%", height=850)
```

### Open report in browser tab instead

```python
report.show("My_EDA_Report.html")   # saves + auto-opens in browser
```

---

## ☁️ Usage in Google Colab

### Step 1 — Install & Upload CSV

```python
!pip install eda-datapilot

import pandas as pd
import datapilot
from google.colab import files

# Upload your CSV file
uploaded = files.upload()
filename = list(uploaded.keys())[0]
df = pd.read_csv(filename)
print(f"Loaded: {df.shape[0]} rows × {df.shape[1]} columns")
```

### Step 2 — Run EDA & Download Report

```python
TARGET = None   # e.g. TARGET = "Price"

report = datapilot.analyze(df, target=TARGET)
report.to_html("My_EDA_Report.html")
files.download("My_EDA_Report.html")
print("Report downloaded!")
```

### Step 3 — View Inline in Colab

```python
from IPython.display import IFrame
IFrame("My_EDA_Report.html", width="100%", height=850)
```

---

## ⚡ Quick Start (Python Script)

```python
import pandas as pd
import datapilot

df = pd.read_csv("data/dataset.csv")

# Set target=None if no target column
report = datapilot.analyze(df, target="target_column")

report.to_html("DataPilot_Report.html")
print("Report saved!")
```

---

## 🔬 Step-by-Step Analysis

Use `EDA` when you need individual results as Python dictionaries:

```python
import pandas as pd
from datapilot import EDA

df = pd.read_csv("data/dataset.csv")
eda = EDA(df, target="target_column")

summary         = eda.summary()          # Dataset overview
missing         = eda.missing()          # Missing values per column
numeric         = eda.numeric()          # Numeric statistics
categorical     = eda.categorical()      # Categorical statistics
duplicates      = eda.duplicates()       # Duplicate rows & columns
correlation     = eda.correlation()      # Pearson / Spearman / Kendall
outliers        = eda.outliers()         # IQR & Z-score outliers
problems        = eda.problems()         # Data quality alerts
recommendations = eda.recommendations()  # Preprocessing suggestions
ml_insights     = eda.ml_insights()     # Feature importance & task type

print(summary)
print(problems)
print(recommendations)

# Generate full HTML report
report = eda.report()
report.to_html("detailed_report.html")
```

---

## ⚙️ Configuration

Customize thresholds, outlier detection, sampling, and report settings:

```python
import pandas as pd
from datapilot import EDA, EDAConfig

df = pd.read_csv("data/dataset.csv")

config = EDAConfig(sample_size=10_000)
config.thresholds.high_correlation = 0.9
config.outliers.iqr_multiplier = 1.5
config.outliers.z_score_threshold = 3.0
config.report.title = "My EDA Report"
config.report.theme = "light"

eda = EDA(df, target="target_column", config=config)
eda.report().to_html("configured_report.html")
```

---

## 📋 Public API Reference

| Object / Method | Description |
|---|---|
| `datapilot.analyze(df, target=None)` | One-liner full EDA → returns `Report` |
| `EDA(df, target=None, config=None)` | Step-by-step analysis class |
| `EDAConfig()` | Configuration for thresholds, outliers, reports |
| `eda.summary()` | Dataset overview (shape, dtypes, memory) |
| `eda.missing()` | Missing values per column |
| `eda.numeric()` | Numeric column statistics |
| `eda.categorical()` | Categorical column statistics |
| `eda.duplicates()` | Duplicate row & column detection |
| `eda.correlation()` | Correlation matrices |
| `eda.outliers()` | Outlier detection (IQR & Z-score) |
| `eda.problems()` | Data quality audit alerts |
| `eda.recommendations()` | Preprocessing recommendations |
| `eda.ml_insights()` | ML task type & feature importance |
| `report.to_html("file.html")` | Save report to HTML file |
| `report.show("file.html")` | Save + open in browser |

---

## 🗂️ Project Layout

```text
datapilot/
├── datapilot/              # Library source code
│   ├── analyzer.py         # EDA and analyze() APIs
│   ├── config.py           # EDAConfig and report settings
│   ├── report.py           # HTML report generation
│   ├── visualization.py    # Plotly & Seaborn chart generators
│   └── templates/          # Jinja2 HTML report template
├── examples/demo.py        # Runnable demo with synthetic data
├── tests/                  # Automated tests
├── pyproject.toml          # Package metadata and dependencies
└── requirements.txt        # Runtime dependencies
```

---

## 🧪 Run the Demo

```bash
python examples/demo.py
```

This creates a synthetic dataset with missing values, outliers, and duplicates, then generates `DataPilot_Demo_Report.html`.

---

## 🧪 Run Tests

```bash
python -m pytest
```

---

## 📄 License

MIT License — see [LICENSE](LICENSE) for details.

---

## 👩‍💻 Author

**Sakshi Nagare** — [sakshinagare2112@gmail.com](mailto:sakshinagare2112@gmail.com)

> ⭐ If you find DataPilot useful, please star the repo and share it with others!
eda.report().to_html("reports/configured_report.html")
```

## Run the Included Demo

The included demo creates a synthetic dataset with missing values, outliers,
duplicates, categorical columns, and a target column. It writes
`DataPilot_Demo_Report.html` to the project directory.

```powershell
python examples\demo.py
```

## Run Tests

```powershell
python -m pytest
```

## Public API

The package exports the following public objects:

```python
from datapilot import EDA, EDAConfig, analyze
```

- `analyze(df, target=None)` runs a complete analysis.
- `EDA(df, target=None, config=None)` provides step-by-step analysis.
- `EDAConfig` configures thresholds, outliers, reports, and sampling.

## Project Layout

```text
datapilot/
├── datapilot/              # Library source code
│   ├── analyzer.py         # EDA and analyze APIs
│   ├── config.py           # EDAConfig and report settings
│   ├── report.py           # HTML report generation
│   └── templates/          # Report template
├── examples/demo.py        # Runnable library example
├── tests/                  # Automated tests and sample data
├── pyproject.toml          # Package metadata and dependencies
└── requirements.txt        # Runtime and test dependencies
```
