Package to calculate Topsis Score
Project description
TOPSIS
Technique for Order Preference by Similarity to Ideal Solution (TOPSIS) originated in the 1980s as a multi-criteria decision making method. TOPSIS chooses the alternative of shortest Euclidean distance from the ideal solution, and greatest distance from the negative-ideal solution.
Steps to install this package:
>> pip install Topsis_Mayank_102097021
Example of how to run this package using CLI:
>> topsis data.csv 1,1,2,1,2 +,+,-,-,+ result.csv
Sample input file (data.csv)
| Fund Name | P1 | P2 | P3 | P4 | P5 |
|---|---|---|---|---|---|
| M1 | 0.84 | 0.71 | 3.6 | 41.8 | 11.74 |
| M2 | 0.65 | 0.42 | 3.4 | 42.2 | 11.67 |
| M3 | 0.73 | 0.53 | 5.9 | 44.8 | 12.99 |
| M4 | 0.84 | 0.71 | 4.3 | 31.1 | 9.24 |
| M5 | 0.70 | 0.49 | 5.3 | 47.8 | 13.57 |
| M6 | 0.63 | 0.40 | 3.8 | 51.4 | 14.06 |
| M7 | 0.71 | 0.50 | 6.3 | 38.7 | 11.55 |
| M8 | 0.83 | 0.69 | 3.0 | 66.4 | 17.73 |
Sample output file (result.csv)
| Fund Name | P1 | P2 | P3 | P4 | P5 | Topsis Score | Rank |
|---|---|---|---|---|---|---|---|
| M1 | 0.84 | 0.71 | 3.6 | 41.8 | 11.74 | 0.558223797 | 2 |
| M2 | 0.65 | 0.42 | 3.4 | 42.2 | 11.67 | 0.436582006 | 4 |
| M3 | 0.73 | 0.53 | 5.9 | 44.8 | 12.99 | 0.348034209 | 7 |
| M4 | 0.84 | 0.71 | 4.3 | 31.1 | 9.24 | 0.419806643 | 5 |
| M5 | 0.7 | 0.49 | 5.3 | 47.8 | 13.57 | 0.404084221 | 6 |
| M6 | 0.63 | 0.4 | 3.8 | 51.4 | 14.06 | 0.50688539 | 3 |
| M7 | 0.71 | 0.5 | 6.3 | 38.7 | 11.55 | 0.220136412 | 8 |
| M8 | 0.83 | 0.69 | 3 | 66.4 | 17.73 | 0.973068125 | 1 |
The output file contains columns of input file along with two additional columns having **Topsis Score** and **Rank**
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file Topsis_Mayank_102097021-1.0.0.tar.gz.
File metadata
- Download URL: Topsis_Mayank_102097021-1.0.0.tar.gz
- Upload date:
- Size: 3.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.26.0 requests-toolbelt/0.9.1 urllib3/1.26.7 tqdm/4.62.3 importlib-metadata/4.8.1 keyring/23.1.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c5f3a381006905523df6b21d541d340600b7686cea9d9b4ee43ad7ca25c82282
|
|
| MD5 |
22aa0e19e78d0b9c378664f31b7a58a7
|
|
| BLAKE2b-256 |
f1af85b6ff7f8508ecbf86a353be52724be6d88623be79bf42948465a94ad200
|