Metadata-Version: 2.4
Name: Topsis-Karan-102317145
Version: 1.0.0
Summary: A command-line implementation of the TOPSIS method.
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: pandas
Requires-Dist: numpy
Dynamic: description
Dynamic: description-content-type
Dynamic: license-file
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# Topsis-Karan-102317145

This is a simple command-line implementation of the TOPSIS method in Python.

TOPSIS stands for Technique for Order Preference by Similarity to Ideal Solution.  
It is a multi-criteria decision-making method used to rank alternatives based on multiple criteria.

This package allows you to:

- Provide a CSV file
- Provide weights for each criterion
- Provide impact (+ or -) for each criterion
- Automatically calculate TOPSIS score
- Get ranking as output in a CSV file

---

## What This Tool Does

1. Cleans the dataset
2. Handles numeric and ordinal data
3. Drops invalid or text-only columns
4. Normalizes the data
5. Applies weights
6. Calculates ideal best and worst
7. Computes TOPSIS score
8. Ranks alternatives
9. Saves result in output CSV

---

##  Installation

You can install the package using pip:

pip install Topsis-Karan-102317145


Make sure you are using Python 3.8 or above.

---

## Input File Format

Your CSV file must:

- Have at least 3 columns
- First column = Name / Identifier
- Remaining columns = Criteria
- Criteria must be numeric or ordinal

Example:
![alt text](image-3.png)


---

##  How To Use (Command Line)

After installation, run: topsis data.csv "1,1,1" "-,+,+” output.csv


### Explanation:

- `data.csv` → Input file
- `"1,1,1"` → Weights for each criterion
- `"- , + , +"` → Impact for each criterion  
   - `+` means benefit (higher is better)
   - `-` means cost (lower is better)
- `output.csv` → Output file name

---

##  Output

The output file will look like:
![alt text](image-2.png)


Higher score means better rank.

---

##  Important Notes

- Number of weights must match number of criteria.
- Number of impacts must match number of criteria.
- Impacts must be only `+` or `-`.
- Missing values are automatically handled.
- Text-only columns are ignored.

---

##  Author

Karan  
Roll No: 102317145  

---

## About TOPSIS

TOPSIS works by:

1. Normalizing the data
2. Applying weights
3. Finding ideal best and worst values
4. Measuring distance from ideal solution
5. Ranking based on closeness

It is commonly used in decision-making problems like:

- Product comparison
- Supplier selection
- Performance evaluation
- Ranking alternatives

---

Thank you for using this package!!



