Skip to main content

Decipy

Multi-Criteria Decision Making Methods library

Installation

$ pip install decipy

or

$ pip install git+https://github.com/justsasri/decipy.git#egg=decipy

MCDM Ranking

import numpy as np
import pandas as pd
from decipy import executors as exe

# define matrix
matrix = np.array([
    [4, 3, 2, 4],
    [5, 4, 3, 7],
    [6, 5, 5, 3],
])

# alternatives
alts = ['A1', 'A2', 'A3']

# criterias
crits = ['C1', 'C2', 'C3', 'C4']

# criteria's beneficial values, True for benefit or False for cost
beneficial = [True, True, True, True]

# criteria's weights
weights = [0.10, 0.20, 0.30, 0.40]

# define DataFrame
xij = pd.DataFrame(matrix, index=alts, columns=crits)

# create Executor (MCDM Method implementation)

kwargs = {
    'data': xij,
    'beneficial': beneficial,
    'weights': weights,
    'rank_reverse': True,
    'rank_method': "ordinal"
}

# Build MCDM Executor
wsm = exe.WSM(**kwargs) # Weighted Sum Method
topsis = exe.Topsis(**kwargs) # Topsis 
vikor = exe.Vikor(**kwargs) # Vikor 

# show results
print("WSM Ranks")
print(wsm.dataframe)

print("TOPSIS Ranks")
print(topsis.dataframe)

print("Vikor Ranks")
print(vikor.dataframe)


# How to choose best MCDM Method ?

# Instantiate Rank Analizer
analizer = exe.RankSimilarityAnalyzer()

# Add MCDMs to anlizer
analizer.add_executor(wsm)
analizer.add_executor(topsis)
analizer.add_executor(vikor)

# run analizer
results = analizer.analyze()
print(results)

references

  • Triantaphyllou, E., Mann, S.H. 1989. "An Examination of The Effectiveness of Multi-dimensional Decision-making Methods: A Decision Making Paradox." Decision Support Systems (5(3)): 303–312.
  • Chakraborty, S., and C.H. Yeh. 2012. "Rank Similarity based MADM Method Selection." International Conference on Statistics in Science, Business and Engineering (ICSSBE2012)
  • Brauers, Willem K., and Edmundas K. Zavadskas. 2009. "Robustness of the multi‐objective MOORA method with a test for the facilities sector." Ukio Technologinisir Ekonominis (15:2): 352-375.
  • Hwang, C.L., and K. Yoon. 1981. "Multiple attribute decision making, methods and applications." Lecture Notes in Economics and Mathematical Systems(Springer-Verlag) 186
  • Yoon, K.P. and Hwang, C.L., “Multiple Attribute Decision Making: An Introduction”, SAGE publications, London, 1995.
  • ÇELEN, Aydın. 2014. "Comparative Analysis of Normalization Procedures in TOPSIS Method: With an Application to Turkish Deposit Banking Market." INFORMATICA 25 (2): 185–208
  • “Ranking”, http://en.wikipedia.org/wiki/Ranking

Metadata

Release files for decision-python 0.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for decision-python 0.0.1
File Size Uploaded Provenance Actions
decision-python-0.0.1.tar.gz 47.1 kB Without provenance Details for decision-python-0.0.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for decision-python 0.0.1
File Interpreter ABI Platform Actions
decision_python-0.0.1-py3-none-any.whl Python 3 none any Details for decision_python-0.0.1-py3-none-any.whl

Total release size: 106.8 kB

Release files / decision-python-0.0.1.tar.gz

Download URL decision-python-0.0.1.tar.gz
Size 47.1 kB
Tags Source
SHA-256 checksum
How to use checksums
14ec3af59d4b94c05991c428d269e5023558fd49a330392c3fe2e8d0c970d91c
BLAKE2b-256 checksum
How to use checksums
c2a7164a59b2fce756fc77da6249768c472843ae494c9776962ad7a4a15f0140
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/47.1.1 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.2

Release files / decision_python-0.0.1-py3-none-any.whl

Download URL decision_python-0.0.1-py3-none-any.whl
Size 59.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2bc5bf206cd7d9702c7cba298a2d6af4d632170dc9d68925cde69a23fa9e2e09
BLAKE2b-256 checksum
How to use checksums
27e9fc7741cb90232be3bcd78ac33d5c8282826b3d3f1e5e9db06171c7149cef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/47.1.1 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.2

Security for decision-python 0.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.0.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page