A Python package implementing TOPSIS technique.
Project 1 : UCS633
Submitted By: Khushnuma Grover 101703289
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-KHUSHNUMA-101703289 can be run as in the following example:
In Command Prompt
>> topsis data.csv "1,1,1,1" "+,+,-,+"
In Python IDLE:
>>> import pandas as pd >>> from topsis_python.topsis import topsis >>> dataset = pd.read_csv('data.csv').values >>> d = dataset[:,1:] >>> w = [1,1,1,1] >>> im = ["+" , "+" , "-" , "+" ] >>> topsis(d,w,im)
The decision matrix (
a) should be constructed with each row representing a Model alternative, and each column representing a criterion like Accuracy, R2, Root Mean Squared Error, Correlation, and many more.
w) is not already normalised will be normalised later in the code.
Information of benefit positive(+) or negative(-) impact criteria should be provided in
Model Score Rank ----- -------- ---- 1 0.77221 2 2 0.225599 5 3 0.438897 4 4 0.523878 3 5 0.811389 1
The rankings are displayed in the form of a table using a package 'tabulate', with the 1st rank offering us the best decision, and last rank offering the worst decision making, according to TOPSIS method.
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Hashes for topsis-101703289-khushnuma-1.0.0.tar.gz
Hashes for topsis_101703289_khushnuma-1.0.0-py3-none-any.whl