Metadata-Version: 2.4
Name: ml1-practicals
Version: 0.1.0
Summary: A collection of 9 Machine Learning practicals and datasets with one-click Downloads export.
Home-page: https://github.com/yourusername/ml-1
Author: Your Name
Author-email: your.email@example.com
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: pandas
Requires-Dist: numpy
Requires-Dist: scikit-learn
Requires-Dist: matplotlib
Dynamic: author
Dynamic: author-email
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: home-page
Dynamic: license-file
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# Machine Learning Practicals Package (`my_ml_package` / `ml-1`)

A comprehensive Python package containing clean implementations and datasets for 9 fundamental Machine Learning practical tasks.

---

## ⚡ Quick Start: Download Practical & Dataset to Your Downloads Folder

Once installed via pip, you can extract any practical code and its dataset right into your **Downloads** folder:

```bash
# Download Practical 1 (practical_1.py + salary.csv)
ml-1 download 1

# Download ALL 9 practicals and all CSVs
ml-1 download all
```
> The folder will open in Windows Explorer. You can double-click or open `practical_1.py` in VS Code / IDLE, inspect the clean code, and run:
> ```bash
> python practical_1.py
> ```

You can also run directly from Python:
```python
import my_ml_package
my_ml_package.download(1)       # Downloads practical 1 + salary.csv
my_ml_package.download('all')   # Downloads all practicals + CSVs
```

---

## Tasks Included

1. **Simple Linear Regression** (`practical_1.py`)
   - Dataset: `salary.csv`
   - Features: `months` -> Target: `salary`
   - Evaluation: MAE, MSE, RMSE

2. **Simple Linear Regression** (`practical_2.py`)
   - Dataset: `rent.csv`
   - Features: `month` -> Target: `rent`
   - Evaluation: MAE, MSE, RMSE

3. **Simple Linear Regression** (`practical_3.py`)
   - Dataset: `sales.csv`
   - Features: `fahrenheit` -> Target: `sales`
   - Evaluation: MAE, MSE, RMSE

4. **Multiple Linear Regression** (`practical_4.py`)
   - Dataset: `house.csv`
   - Features: Square footage, bedrooms, bathrooms, etc. -> Target: `price`
   - Evaluation: MAE, MSE, RMSE

5. **Multiple Linear Regression** (`practical_5.py`)
   - Dataset: `income.csv`
   - Features: `age`, `experience` -> Target: `income`
   - Evaluation: MAE, MSE, RMSE

6. **Logistic Regression** (`practical_6.py`)
   - Dataset: Scikit-learn Built-in Digits Dataset
   - Multi-class classification (0-9 digits)
   - Evaluation: Confusion Matrix, Classification Report, 5-Fold Cross Validation

7. **Support Vector Machine (SVM)** (`practical_7.py`)
   - Dataset: Scikit-learn Built-in Iris Dataset
   - Linear SVM classification
   - Evaluation: Confusion Matrix, Classification Report, 5-Fold Cross Validation

8. **Bagging Ensemble Classifier** (`practical_8.py`)
   - Dataset: Scikit-learn Built-in Wine Dataset
   - Bagging with Decision Trees (50 estimators)
   - Evaluation: Confusion Matrix, Classification Report, 5-Fold Cross Validation

9. **Principal Component Analysis (PCA)** (`practical_9.py`)
   - Dataset: Scikit-learn Built-in Wine Dataset
   - 2D dimensionality reduction and visualization with Matplotlib

---

## Installation

### From Local Source (Development Mode):
```bash
cd my_ml_package
pip install -e .
```

### From PyPI (once published):
```bash
pip install <your-chosen-package-name>
```

---

## How to Run in Terminal

### Option 1: Command Line CLI
```bash
# Run Practical 1
ml-1 1

# Run all practicals
ml-1 all

# Download Practical 1 into Downloads
ml-1 download 1
```

### Option 2: Python Code Import
```python
from my_ml_package import practical_1, run_practical, run_all

# Run a single practical
result_1 = practical_1.run()

# Run all practicals
run_all()
```

---

## Packaging & Publishing to PyPI

### 1. Set Your Unique PyPI Package Name
Open `setup.py` and set `name='your-unique-name'` (e.g. `ml-practicals-kadam`).

### 2. Build Distribution Files
```bash
python -m build
```

### 3. Upload to PyPI
```bash
twine upload dist/*
```
Enter `__token__` as the username and your PyPI API token as the password.

---

## License
MIT License
