crispyn.mcda_methods.vikor ========================== .. py:module:: crispyn.mcda_methods.vikor Classes ------- .. autoapisummary:: crispyn.mcda_methods.vikor.VIKOR Module Contents --------------- .. py:class:: VIKOR(normalization_method=None, v=0.5) Bases: :py:obj:`crispyn.mcda_methods.mcda_method.MCDA_method` Helper class that provides a standard way to create an ABC using inheritance. .. py:attribute:: v :value: 0.5 .. py:attribute:: normalization_method :value: None .. py:method:: __call__(matrix, weights, types) Score alternatives provided in decision matrix `matrix` using criteria `weights` and criteria `types`. Parameters ----------- matrix : ndarray Decision matrix with m alternatives in rows and n criteria in columns. weights: ndarray Matrix containing vectors with criteria weights in subsequent rows. Sum of weights in each vector must be equal to 1. types: ndarray Vector with criteria types. Profit criteria are represented by 1 and cost by -1. Returns -------- ndrarray Matrix with vectors containing preference values of each alternative. The best alternative has the lowest preference value. Vectors are placed in subsequent columns of matrix. Examples --------- >>> vikor = VIKOR(normalization_method = minmax_normalization) >>> pref = vikor(matrix, weights, types) >>> rank = np.zeros((pref.shape)) >>> for i in range(pref.shape[1]): >>> rank[:, i] = rank_preferences(pref[:, i], reverse = False) .. py:method:: _vikor(matrix, weights, types, normalization_method, v) :staticmethod: