# R language modeling for multivariate statistical analysis

• Characteristic:
• It includes several indicators, and the variation shows different aspects of the evaluation object
• To make an overall evaluation of the evaluated object, use a general indicator to explain the general level of the evaluated object
• Principles of index system construction
• System comprehensiveness
• Stable comparability
• Concise and scientific
• Flexible operation
• Weight determination of index system
• Proportion of importance of indicators in indicator group
• Delphi method to determine the weight
• Experts evaluate the importance of each evaluation index
• Experts score
• Analytic hierarchy process
• The relative importance of each index is compared, and then the weight of each evaluation index is determined by objective operation
• Constructing judgment matrix
• Weight calculation of each index
• Consistency test of judgment matrix
• Dimensionless index
• Standardized transformation
• Normalized transformation
• Efficiency coefficient transformation
• Exponential transformation
• • Dimensionless use
• Comprehensive scoring method
``````A=matrix(c(1,1/3,1/7,3,1,1/3,7,3,1),3,3)
A
#AHP process, consistency test
A_W=msa.AHP(A)
A_W
#Patent data standardization
zf<-function(x){ z=(x-min(x))/(max(x)-min(x))*60+40; z }
A1=d13.1[,1:6];A1    #Extract the first six variables

A1_Z=apply(A1,2,zf); A1_Z

X_Z<-function(X){    #Self made normalized transformation function

Z=apply(X,2,zf)
Z
}

A1_Z=X_Z(A1); A1_Z  #Normalization transformation of example data

# The weight of comprehensive scoring method is 1
A1_S1=apply(A1_Z,1,mean)
A1_S1
cbind(A1_Z,A1_S1,A1_R1=rank(-A1_S1))  #Ranking by comprehensive score

#Analytic hierarchy process
B1=matrix(c(1,4,5,3,6,7,1/4,1,2,1/2,3,4,1/5,1/2,1,1/3,2,3,1/3,  2,  3,  1,  4,5,
1/6,1/3,1/2,1/4,1,2,1/7,1/4,1/3,1/5,1/2,1),6,6,byrow=T); B1  #Construct the judgment matrix of B1

B1_W=msa.AHP(B1);B1_W    #Weight of B1

A1_S2=A1_Z%*%B1_W        #AHP comprehensive score
data.frame(A1_Z,A1_S2,A1_R2=rank(-A1_S2))  #AHP comprehensive ranking

data.frame('Comprehensive score'=A1_S1,'Comprehensive ranking'=rank(-A1_S1),
'Level score'=A1_S2,'Hierarchical ranking'=rank(-A1_S2))  #Building a comprehensive score and ranking data box

B2=matrix(c(1,4,5,7,8,9,1/4,1,2,4,5,6,1/5,1/2,1,3,4,5,1/7,1/4,1/3,1,2,3,1/8,1/5,
1/4,1/2,1,2,1/9,1/6,1/5,1/3,1/2,1),6,6,byrow=T); B2 #Construct the judgment matrix of B2
B2_W=msa.AHP(B2);B2_W        #Weight of B2
round(B2_W,4)

B3=matrix(c(1,5,2,6,2,6,1,1/5,1,1/4,2,1/4,2,0.2,1/2,5,1,5,1,5,1/2,1/6,1/2,1/5,
1,1/5,1,1/6,1/2,4,1,5,1,5,1/2,1/6,1/2,1/5,1,1/5,1,1/6,1,5,2,2,2,6,1),7,7,byrow=T)
#Constructing the judgment matrix of B3
B3_W=msa.AHP(B3);B3_W        #Weight of B3

A2=d13.1[,8:13]              #Group A2 data
A3=d13.1[,14:20]             #Group A3 data
A2_S=X_Z(A2)%*%B2_W          #A2 score
A3_S=X_Z(A3)%*%B3_W          #A3 score
A_d=cbind(A1_S,A2_S,A3_S)    #A data frame
A_S=A_d%*%A_W; A_S           #A score
data.frame('A1 Score'=A1_S,'A1 ranking'=rank(-A1_S),'A2 Score'=A2_S,'A2 ranking'=rank(-A2_S),
'A3 Score'=A3_S,'A3 ranking'=rank(-A3_S),'Composite score'=A_S,'Comprehensive ranking'=rank(-A_S))  #Building a comprehensive score and ranking data box
``````

Tags: Big Data Delphi

Posted on Wed, 15 Apr 2020 09:05:06 -0700 by jsim