plot.ordEval | R Documentation |
The method plot
visualizes the results of ordEval algorithm with an adapted
box-and-whiskers plots. The method printOrdEval
prints summary of the results
in a text format.
plotOrdEval(file, rndFile, ...) ## S3 method for class 'ordEval' plot(x, graphType=c("avBar", "attrBar", "avSlope"), ...) printOrdEval(x)
x |
The object containing results of ordEval algorithm obtained by calling |
file |
Name of file where evaluation results of ordEval algorithm were written to. |
rndFile |
Name of file where evaluation of random normalizing attributes by ordEval algorithm were written to. |
graphType |
The type of the graph to produce. Can be any of |
... |
Other options controlling graphical output, used by specific graphical methods. See details. |
The output of function ordEval
either returned directly or stored in files file
and rndFile
is read and visualized. The type of graph produced is controlled by graphType
parameter:
avBar
the positive and negative reinforcement of each value of each attribute is visualized
as the length of the bar. For each value also a normalizing modified box and whiskers plot
is produced above it, showing the confidence interval of the same attribute value under the assumption
that the attribute contains no information. If the length of the bar is outside the normalizing whiskers, this
is a statistically significant indication that the value is important.
attrBar
the positive and negative reinforcement for each attribute is visualized
as the length of the bar. This reinforcement is weighted sum of contributions of individual
values visualized with avBar
graph type.
avSlope
the positive and negative reinforcement of each value of each attribute is visualized
as the slope of the line segment connecting consequent values
The avBar
and avSlope
produce several graphs (one for each attribute). In order to see them all on
an interactive device use devAskNewPage
. On some platforms or in RStudio environment the graphical window stores the
history and one can browse through recent pages. Alternatively use any of non-interactive devices
such as pdf
or postscript
. Some support for opening and handling of these devices is provided
by function preparePlot
. The user should take care to call dev.off
after completion of the operations.
There are some additional optional parameters ... which are important to all or for some graph types.
ciType
The type of the confidence interval in "avBar" and "attrBar" graph types. Can be "two.sided"
, "upper"
, "lower"
, or "none"
.
Together with ordEvalNormalizingPercentile
parameter in ordEval
, ciType
, ciDisplay
,
and ciDecorate
controls the type, length and display of confidence intervals for each value.
ciDisplay
The way how confidence intervals are displayed. Can be "box"
or "color"
. The value "box"
displays confidence interval as box and whiskers plot above the actual value with whiskers representing confidence percentiles.
The value "color"
displays only the upper limit of confidence interval, namely the value
(represented with a length of the bar) beyond the confidence interval is displayed with more intensive color or shade.
ciDecorate
controls if the reinforcement factors stretching outside the confidence intervals of possible random effects are decorated by being circled with an ellipse. The default value NULL means that there are no decorations, other values are interpreted as colors in the function draw.elipse
, e.g., ciDecorate="red"
draws red ellipses around statisticaly significant reinforcemnets.
equalUpDown
a boolean specifying if upward and downward reinforcement of the same value are to be displayed
side by side on the same level; it usually makes sense to
set this parameter to TRUE
when specifying a single value differences by setting variant="attrDist1"
in
ordEval
function.
graphTitle
specifies text to incorporate into the title.
attrIdx
displays plot for a single attribute with specified index.
xlabel
label of lower horizontal axis.
ylabLeft
label of the left-hand vertical axis.
ylabRight
label of the right-hand vertical axis.
colors
a vector with four colors specifying colors of reinforcement bars for down, down_beyond, up, and up_beyond, respectively. If set to NULL this produces black and white graph with shades of gray.
The colors down_beyond and up_beyond depict the confidence interval if parameter ciDisplay="color"
.
The default values are colors=c("green","lightgreen","blue","lightblue")
.
The method returns no value.
Marko Robnik-Sikonja
Marko Robnik-Sikonja, Koen Vanhoof: Evaluation of ordinal attributes at value level. Knowledge Discovery and Data Mining, 14:225-243, 2007
Marko Robnik-Sikonja, Igor Kononenko: Theoretical and Empirical Analysis of ReliefF and RReliefF. Machine Learning Journal, 53:23-69, 2003
Some of the references are available also from http://lkm.fri.uni-lj.si/rmarko/papers/
ordEval
,
helpCore
,
preparePlot
,
CORElearn
# prepare a data set dat <- ordDataGen(200) # evaluate ordered features with ordEval oe <- ordEval(class ~ ., dat, ordEvalNoRandomNormalizers=200) plot(oe) # printOrdEval(oe) # the same effect we achieve by storing results to files tmp <- ordEval(class ~ ., dat, file="profiles.oe", rndFile="profiles.oer", ordEvalNoRandomNormalizers=200) plotOrdEval(file="profiles.oe", rndFile="profiles.oer", graphType="attrBar") # clean up for the sake of R package checks file.remove("profiles.oe") file.remove("profiles.oer")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.