| rie.d | R Documentation |
Calculate the information error and relative information error using the data as the input. The data will be transformed to discretized data, from where the probability is calculated.
rie.d( X, rvars, svars, contivars = NULL, method = "emp", disc = "equalfreq", nbins = nrow(X)^(1/3) )
X |
matrix or data.frame containing all variables |
rvars |
relevant variables |
svars |
selected variables |
contivars |
which variables are continuous? By default, only continuous variables will be discretized. If NULL, all variables are continuous. |
method |
the name of the entropy estimator. We use the entropy computation of the infotheo package, where four methods are includes: "emp", "mm", "shrink", "sg". For more details, see entropy() in "infotheo" package. |
disc |
the strategies to discretize data. Three options are provided: "equalfreq", "equalwidth", and "globalequalwidth". See discretize() in "infotheo" package. |
nbins |
iteger specifying the number of bins to be used for the discretization |
Shuo Wang
m <- GenMatrix(3, rlist = list(c(1, 2, 0.5), c(1, 3, 0.3), c(2, 3, 0.7)))
D <- GenData(100, rmatrix = m)
rvars = c("x1", "x2")
svars = c("x2", "x3")
rie.d(D, rvars, svars)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.