Skip to main content

A package that makes it easy to create Pypi packages

Project description

TOPSIS-Rohan-101803151

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. As the name implies, the method is based on finding an ideal and an anti-ideal solution and comparing the distance of each one of the alternatives to those.

Installing Guide

The package TOPSIS-Rohan-101803151 can be run though the command line as follows:

>> pip install TOPSIS-Rohan-101803151==1.0.3
>> python
>>>from topsis_analysis.topsispackage import topsis
>>>topsis("data.csv","1,1,1,2","+,+,-,+","output.csv")

Note:

  • Usages:

    topsis( <InputDataFile> <Weights> <Impacts> <ResultFileName>)

  • Input File:

    • Input file contain three or more columns.
    • First column is the object/variable name (e.g. M1, M2, M3, M4……) .
    • From 2nd to last columns contain numeric values only.
  • Output File:

    • Result file contains all the columns of input file and two additional columns having TOPSIS SCORE and RANK
  • The output is created in the form of csv file and stored and also it is displayed.

  • The impacts given in the command line should be either ‘+’ or ‘–’ depending if you want to maximise the column parameter or minimise it.

Sample Input

Here is a sample set of data which can be used for the following package:

ModelCorrelationR2RMSEAccuracy
M10.790.621.2560.89
M20.660.442.8963.07
M30.560.311.5762.87
M40.820.672.6870.19
M50.750.561.380.39

Output of this sample input

The output that will be generated from the following input data will be:

ModelCorrelationR2RMSEAccuracyTopsis ScoreRank
M10.790.621.2560.890.63913301413425902.0
M20.660.442.8963.070.212591829692779005.0
M30.560.311.5762.870.40784567761305204.0
M40.820.672.6870.190.51915323950074703.0
M50.750.561.380.390.82826658519358101.0

Here the ranks are given as rank 1 is the best solution according to the weights and impacts given and rank 5 is the worst solution.

Hence this python package creates a Result file contains all the columns of input file and two additional columns having TOPSIS SCORE and RANK


Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

TOPSIS-Rohan-101803151-v08-1.0.8.tar.gz (4.0 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page