TOPSIS-Python
Submitted By: Arindam Sharma
What is 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. More details at wikipedia.
How to use this package:
>> topsis data.csv "1,1,1,1" "+,+,-,+" output.csv
Sample dataset
The decision matrix (a) should be provided with more than two columns and should be in .csv format.
| Model | Correlation | R2 | RMSE | Accuracy |
|---|---|---|---|---|
| M1 | 0.79 | 0.62 | 1.25 | 60.89 |
| M2 | 0.66 | 0.44 | 2.89 | 63.07 |
| M3 | 0.56 | 0.31 | 1.57 | 62.87 |
| M4 | 0.82 | 0.67 | 2.68 | 70.19 |
| M5 | 0.75 | 0.56 | 1.3 | 80.39 |
Weights (w) and impacts (either + or -) should also be provided alogn with.
Output
The output comes out in a csv file as the format given below :
Model | Correlation | R<sup>2</sup> | RMSE | Accuracy | Topsis Score | Rank
------------ | ------------- | ------------ | ------------- | ------------
M1 | 0.79 | 0.62 | 1.25 | 60.89 | 0.639133 | 2
M2 | 0.66 | 0.44 | 2.89 | 63.07 | 0.212592 | 5
M3 | 0.56 | 0.31 | 1.57 | 62.87 | 0.407846 | 4
M4 | 0.82 | 0.67 | 2.68 | 70.19 | 0.519153 | 3
M5 | 0.75 | 0.56 | 1.3 | 80.39 | 0.828267 | 1
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-Arindam-101816003-0.0.1.tar.gz.
File metadata
- Download URL: TOPSIS-Arindam-101816003-0.0.1.tar.gz
- Upload date:
- Size: 4.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/3.2.0 pkginfo/1.6.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dac2ce9bd41ab1c01682001449fcb3c06b72599ad6450aceabfb208d9112dcc9
|
|
| MD5 |
4d89bc8eba13eb3949ea0f6592f637aa
|
|
| BLAKE2b-256 |
ce4519b4cc7435a2cb8cc18c94f9eb072ca4bd8a825745a98fa1bba2ec30a0af
|