semvec/pypi-packages huggingface dataset:
Topsis-ManviSingla-102003505 1.0
Topsis

# Title:Multiple Criteria Decision Making using TOPSIS

## What is TOPSIS:
TOPSIS is an acronym that stands for 'Technique of Order Preference Similarity to the Ideal Solution' and is a pretty straightforward MCDA method. It is a multi-criteria decision analysis method, which was originally developed by Ching-Lai Hwang and Yoon in 1981 with further developments by Yoon in 1987, and Hwang, Lai and Liu in 1993.

## How to get output?
output is taken by running the command on terminal as : python "sourcefile.py" "input.csv" "weights(separateed by ',')" "impact(separated by ','))" use impact as '+' for maximizing the feature and '-' for minimizing. On your terminal run the command:
python source_file_name.py input_file.csv "1,1,0,1" "+,-,+,+" output_file_name.csv Output will be stored in your present working directory as a csv file.

## Constraints
Number of columns in input file(other than the name of the entity) should be equal to length of impacts and length of weights.

Input file should not have blank values

Number of Columns in Input files should not be less than 3

There should not be any csv file with same name as your output file in present directory

Number of Arguments should be equal to the number as specified above

## INPUT FILE(EXAMPLE:DATA.CSV):
Argument used to pass the path of the input file which conatins a dataset having different fields and to perform the topsis mathematical operations

## WEIGHTS(EXAMPLE:"0.25,0.25,0.25,0.25")
The weights to assigned to the different parameters in the dataset should be passed in the argument.It must be seperated by ','.

## IMPACTS(EXAMPLE:"-,+,+,+"):
The impacts are passed to consider which parameters have a positive impact on the decision and which one have the negative impact.Only '+' and '-' values should be passed and should be seperated with ',' only

## OUTPUT FILE(EXAMPLE:RESULT.CSV):
This argument is used to pass the path of the result file where we want the rank and score to be stored
Topsis-Sanjoli-102003425 0.5
This is a topsis package of version 0.5

## Topsis:-MULTIPLE-CRITERIA DECISION MAKING

# TOPSIS

Submitted By: **SANJOLI AGARWAL 102003425**.

Date: **21-JAN-2023**.

Description: **Evaluation of alternatives based on multiple criteria using TOPSIS method.**.

---

## What is TOPSIS?

**T**echnique for **O**rder **P**reference by **S**imilarity to **I**deal **S**olution
TOPSIS chooses the alternative of shortest Euclidean distance from the ideal solution,
and greatest distance from the negative-ideal solution.

<br>

## How to install this package:

```
>>pip install Topsis_Sanjoli_102003425
```

### In Command Prompt

```
>> topsis data.csv "1,1,1,1" "+,+,-,+" result.csv
```

## Input file (data.csv)

The decision matrix should be constructed with each row representing a Model alternative, and each column representing a criterion like Attribute, Price or cost, Storage Space ,Camera,Looks.

| Attribute | Price or cost | Storage Space | Camera| Looks |
| -----     | -----------   | ------------- | ---- | -------|
| Mobile 1  | 250$          | 16GB          | 12MP | 5      |
| Mobile 2  | 200$          | 16GB          | 8MP  | 3      |
| Mobile 3  | 300$          | 32GB          | 16MP | 4      |
| Mobile 4  | 275$          | 32GB          | 8MP  | 4      |
| Mobile 5  | 225$          | 16GB          | 16MP | 2      |

Weights (`weights`) is not already normalised will be normalised later in the code.

Information of benefit positive(+) or negative(-) impact criteria should be provided in `impacts`.

<br>

## Output file (result.csv)

| Attribute | Price or cost | Storage Space | Camera| Looks | Topsis_score | Rank|
| -----     | -----------   | ------------- | ---- | -------| ------------ | ----|
| Mobile 1  |250$           | 16GB          | 12MP | 5      | 0.4228       | 4   |
| Mobile 2  |200$           | 16GB          | 8MP  | 3      | 0.4635       | 3   |
| Mobile 3  |300$           | 32GB          | 16MP | 4      | 0.5097       | 2   |
| Mobile 4  |275$           | 32GB          | 8MP  | 4      | 0.3772       | 5   |
| Mobile 5  |225$           | 16GB          | 16MP | 2      | 0.6871       | 1   |


<br>
The output file contains columns of input file along with two additional columns having **Topsis_score** and **Rank**