Title: | Weighted Method for Multiple-Criteria Decision Making |
Version: | 1.0 |
Maintainer: | zhengyu wu <zhengyuwu888@163.com> |
Description: | Evaluation of alternatives based on multiple criteria using weighted technique for Order preference by similarity to an ideal solution method. Reference: Hwang CL. (1981, ISBN:978-3-540-10558-9). |
License: | MIT + file LICENSE |
Encoding: | UTF-8 |
LazyData: | true |
RoxygenNote: | 7.1.2 |
Depends: | R (≥ 2.10) |
Suggests: | testthat (≥ 3.0.0) |
Config/testthat/edition: | 3 |
NeedsCompilation: | no |
Packaged: | 2021-10-26 08:58:55 UTC; Administrator |
Author: | zhengyu wu [aut, cre, ctb] |
Repository: | CRAN |
Date/Publication: | 2021-10-26 14:50:02 UTC |
DataNormal Normalize the maximized data set.
Description
DataNormal Normalize the maximized data set.
Usage
DataNormal(data)
Arguments
data |
A maximized data set |
Value
A Normalized data set
Examples
## Not run:
sampleData<-sampleData
mth<-c("ZH","ZJ","QJ","ZH","FU","ZH","QJ","FU","FU","ZH")
zmth<-c(NA,NA,NA,NA,"CZ",NA,NA,"DS","CZ",NA)
xbest<-c(NA,4,NA,NA,NA,NA,NA,NA,NA,NA)
qup<-c(NA,NA,5,NA,NA,NA,5,NA,NA,NA)
qlow<-c(NA,NA,3,NA,NA,NA,3,NA,NA,NA)
maxdata<-data2max(sampleData,mth,zmth,xbest,qlow,qup)
DataNormal(maxdata)
## End(Not run)
DataNormalpre Prepare the normalized data set.
Description
DataNormalpre Prepare the normalized data set.
Usage
DataNormalpre(data, i)
Arguments
data |
A maximized data set |
i |
Index column |
Value
Index column normalized
Ejcaul Calculate Ej value.
Description
Ejcaul Calculate Ej value.
Usage
Ejcaul(data, i)
Arguments
data |
A normalized data set. |
i |
Index column. |
Value
Index column weight Ej
Errmax Function on error.
Description
Errmax Function on error.
Usage
Errmax(x, i)
Arguments
x |
The Data that needs to be maximized. |
i |
Index column. |
Value
Index column maximized.
GetWeight Calculate weights on standardized data us the entropy method.
Description
GetWeight Calculate weights on standardized data us the entropy method.
Usage
GetWeight(data)
Arguments
data |
A Normalized data set |
Value
WeightEij is Ej value of Index,weight is weight value of Index
Examples
sampleData<-sampleData
mth<-c("ZH","ZJ","QJ","ZH","FU","ZH","QJ","FU","FU","ZH")
zmth<-c(NA,NA,NA,NA,"CZ",NA,NA,"DS","CZ",NA)
xbest<-c(NA,4,NA,NA,NA,NA,NA,NA,NA,NA)
qup<-c(NA,NA,5,NA,NA,NA,5,NA,NA,NA)
qlow<-c(NA,NA,3,NA,NA,NA,3,NA,NA,NA)
weightdata<-data2max(sampleData,mth,zmth,xbest,qlow,qup)
GetWeight(weightdata)
WtTopsis Weighted TOPSIS method for multiple-criteria decision making (MCDM).
Description
WtTopsis Weighted TOPSIS method for multiple-criteria decision making (MCDM).
Usage
WtTopsis(data, mth, zmth, xbest, qlow, qup)
Arguments
data |
The Data that needs to be maximized. |
mth |
A vector describing the type of each indicator. |
zmth |
A vector describing the method from negative to positive, including DS: reciprocal method, it is not recommended to use when the data has 0, CZ: using the maximum subtraction method, other types of indicators are marked as NA. |
xbest |
An optimal value vector of intermediate numerical values,other types of indicators are marked as NA. |
qlow |
An interval lower bound vector with interval numeric value forward,other types of indicators are marked as NA. |
qup |
An interval upper bound vector of the interval value maximize,other types of indicators are marked as NA. |
Value
Data set containing D+,D- and C values
Examples
sampleData<-sampleData
mth<-c("ZH","ZJ","QJ","ZH","FU","ZH","QJ","FU","FU","ZH")
zmth<-c(NA,NA,NA,NA,"CZ",NA,NA,"DS","CZ",NA)
xbest<-c(NA,4,NA,NA,NA,NA,NA,NA,NA,NA)
qup<-c(NA,NA,5,NA,NA,NA,5,NA,NA,NA)
qlow<-c(NA,NA,3,NA,NA,NA,3,NA,NA,NA)
WtTopsis(sampleData,mth,zmth,xbest,qlow,qup)
WtTopsis Weighted TOPSIS method for multiple-criteria decision making (MCDM) us Normalized data.
Description
WtTopsis Weighted TOPSIS method for multiple-criteria decision making (MCDM) us Normalized data.
Usage
WtTopsisN(data)
Arguments
data |
Normalized data. |
Value
Data set containing D+,D- and C values
Examples
sampleData<-sampleData
mth<-c("ZH","ZJ","QJ","ZH","FU","ZH","QJ","FU","FU","ZH")
zmth<-c(NA,NA,NA,NA,"CZ",NA,NA,"DS","CZ",NA)
xbest<-c(NA,4,NA,NA,NA,NA,NA,NA,NA,NA)
qup<-c(NA,NA,5,NA,NA,NA,5,NA,NA,NA)
qlow<-c(NA,NA,3,NA,NA,NA,3,NA,NA,NA)
maxdata<-data2max(sampleData,mth,zmth,xbest,qlow,qup)
normaldata<-DataNormal(maxdata)
WtTopsisN(normaldata)
data2max Maximized the data.
Description
data2max Maximized the data.
Usage
data2max(data, mth, zmth, xbest, qlow, qup)
Arguments
data |
The Data that needs to be maximized. |
mth |
A vector describing the type of each indicator. |
zmth |
A vector describing the method from negative to positive, including DS: reciprocal method, it is not recommended to use when the data has 0, CZ: using the maximum subtraction method, other types of indicators are marked as NA. |
xbest |
An optimal value vector of intermediate numerical values,other types of indicators are marked as NA. |
qlow |
An interval lower bound vector with interval numeric value forward,other types of indicators are marked as NA. |
qup |
An interval upper bound vector of the interval value maximize,other types of indicators are marked as NA. |
Value
A maximized data set
Examples
sampleData<-sampleData
mth<-c("ZH","ZJ","QJ","ZH","FU","ZH","QJ","FU","FU","ZH")
zmth<-c(NA,NA,NA,NA,"CZ",NA,NA,"DS","CZ",NA)
xbest<-c(NA,4,NA,NA,NA,NA,NA,NA,NA,NA)
qup<-c(NA,NA,5,NA,NA,NA,5,NA,NA,NA)
qlow<-c(NA,NA,3,NA,NA,NA,3,NA,NA,NA)
data2max(sampleData,mth,zmth,xbest,qlow,qup)
max2max positive Data conversion.
Description
max2max positive Data conversion.
Usage
max2max(x, i)
Arguments
x |
The Data that needs to be maximized. |
i |
Index column. |
Value
Index column maximized
min2maxC negative Data conversion use Maximum subtraction method
Description
min2maxC negative Data conversion use Maximum subtraction method
Usage
min2maxC(x, i)
Arguments
x |
The Data that needs to be maximized. |
i |
Index column. |
Value
Index column maximized
min2maxD negative Data conversion use reciprocal method
Description
min2maxD negative Data conversion use reciprocal method
Usage
min2maxD(x, i)
Arguments
x |
The Data that needs to be maximized. |
i |
Index column. |
Value
Index column maximized
qj2max Interval Data conversion
Description
qj2max Interval Data conversion
Usage
qj2max(x, qlow, qup, i)
Arguments
x |
The Data that needs to be maximized. |
qlow |
An interval lower bound vector with interval numeric value forward,other types of indicators are marked as NA. |
qup |
An interval upper bound vector of the interval value maximize,other types of indicators are marked as NA. |
i |
Index column. |
Value
Index column maximized
A example of multiple-criteria decision making data.
Description
A example of multiple-criteria decision making data.
Usage
sampleData
Format
A data fram with 21 rows and 11 variables.
Source
Randomly generated.
zj2max Intermediate Data conversion
Description
zj2max Intermediate Data conversion
Usage
zj2max(x, xbest, i)
Arguments
x |
The Data that needs to be maximized. |
xbest |
An optimal value vector of intermediate numerical values,other types of indicators are marked as NA. |
i |
Index column. |
Value
Index column maximized