Description Usage Arguments Examples
first function: grey relational degree, which is similar to orrelation coefficient, if you want to evaluate some unit, please transpose data frame before using this function.
second funtion: grey clustering, like hierarchical clustering, see hclust
.
1 2 |
df |
a data frame with standardized data which can aviod the effects of dimensions. Note: it must includes reference sequence. |
referColNum |
the number of reference sequence in |
distingCoeff |
distinguishing coefficient, the smaller the higher distinguish. |
cluster |
logical value, indicates whether to cluster, default is |
clusterMethod |
method of cluster. |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | ## generate data
refer = c(1,1,1,1)
liaoning = c(0.064, 0.082,0.978,0.423)
shandong = c(0.101,0.3,1,0.917)
jiangsu = c(0.114,0.14,0.943, 0.315)
zhejiang = c(0.102,0.147,0.934,0.395)
fujian = c(0.022,0.053,0.927,0.061)
guangdong = c(1,1,0.012,1)
economyCompare = data.frame(refer, liaoning, shandong, jiangsu, zhejiang, fujian, guangdong)
rownames(economyCompare) = c("indGV", "indVA", "profit", "incomeTax")
## Grey Relational Degree
greyRelDegree = GRA(economyCompare)
greyRelDegree
## Grey Clustering
GRA(economyCompare, cluster = T)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.