MSU is a generalization of symmetrical uncertainty
(SU
) where it is considered
the interaction between two or more variables, whereas SU can only
consider the interaction between two variables. For instance,
consider a table with two variables X1 and X2 and a third variable,
Y (the class of the case), that results from the logical XOR
operator applied to X1 and X2
X1 | X2 | Y |
0 | 0 | 0 |
0 | 1 | 1 |
1 | 0 | 1 |
1 | 1 | 0 |
For this case
msu(table_variables, table_class)
A list of factors as categorical variables.
A factor representing the class of the case.
Multivariate symmetrical uncertainty estimation for the
variable set {table_variables
,
table_class
}. The result is round
ed to 7 decimal
places.
# NOT RUN {
# completely predictable
msu(list(factor(c(0,0,1,1))), factor(c(0,0,1,1)))
# XOR
msu(list(factor(c(0,0,1,1)), factor(c(0,1,0,1))), factor(c(0,1,1,0)))
# }
# NOT RUN {
msu(c(factor(c(0,0,1,1)), factor(c(0,1,0,1))), factor(c(0,1,1,0)))
msu(list(factor(c(0,0,1,1)), factor(c(0,1,0,1))), c(0,1,1,0))
# }
Run the code above in your browser using DataLab