Skip to main content

Decision support system with AHP

Project description

Project Description

Decision support systems are used in industry, to assist users in making decisions. Many methods are used in decision making, one of which is the Analytical Hierarchy Process (AHP). In this method, several layers can be used in decision making. This package has been designed to solve the AHP method with several layers.

Depedencies

  • Python >= 3
  • numpy

How to use

  • run(layers)

Parameters

layers : iterable, array, np.array

The structure of your AHP model (single layer or multi layer).

Example structure

  • Goal
  • Layer 1
    • Node 1
    • Node 2
    • Node 3
  • Layer 2
    • Node 1
    • Node 2
  • Alternatives Layer
    • Alternative 1
    • Alternative 2
    • Alternative 3
    • Alternative 4

Example of code

from stahp import stahp

print(stahp.run(
[
    [
        [1, .3, 5],
        [3, 1, 5],
        [.2, .2, 1]
    ],
    [
        [
            [1, .2],
            [5, 1]
        ],
        [
            [1, 3],
            [.3, 1]
        ],
        [
            [1, 4],
            [.25, 1]
        ]
    ],
    [
        [
            [1, 3, .25, 7],
            [.3, 1, .25, 7],
            [4, 4, 1, 9],
            [.14, .14, .11, 1]
        ],


        [
            [1, 3, .25, 7],
            [.3, 1, .25, 7],
            [4, 4, 1, 9],
            [.14, .14, .11, 1]
        ]
    ]
]
))

Example of output

[0.2502 0.1562 0.5556 0.038 ] #alternative 3 is the best choice

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

stahp-0.1.5.tar.gz (4.0 kB view details)

Uploaded Source

File details

Details for the file stahp-0.1.5.tar.gz.

File metadata

  • Download URL: stahp-0.1.5.tar.gz
  • Upload date:
  • Size: 4.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/3.10.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.1

File hashes

Hashes for stahp-0.1.5.tar.gz
Algorithm Hash digest
SHA256 1d76794818f348afc95201bed1e60eba5fd3a299bf2ebf797954d72ca5f5a670
MD5 f4fecbfa2e398fc30f8d61d8978cf434
BLAKE2b-256 a51923ff212c0c089bbfdcbd44ad2526857ed7810dc8ac4953bcb5b231e6b9b1

See more details on using hashes here.

Supported by

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