Learn R Programming

caret (version 4.47)

dotplot.diff.resamples: Lattice Functions for Visualizing Resampling Differences

Description

Lattice functions for visualizing resampling result differences between models

Usage

## S3 method for class 'diff.resamples':
densityplot(x, data, metric = x$metric, ...)

## S3 method for class 'diff.resamples': bwplot(x, data, metric = x$metric, ...)

## S3 method for class 'diff.resamples': levelplot(x, data = NULL, metric = x$metric[1], what = "pvalues", ...)

## S3 method for class 'diff.resamples': dotplot(x, data = NULL, metric = x$metric[1], ...)

Arguments

x
an object generated by diff.resamples
data
Not used
what
levelplot only: display either the "pvalues" or "differences"
metric
a character string for which metrics to plot. Note: dotplot and levelplot require exactly two models whereas the other methods can plot more than two.
...
further arguments to pass to either histogram, densityplot, dotp

Value

  • a lattice object

Details

densityplot and bwplot display univariate visualizations of the resampling distributions. levelplot displays the matrix of pair-wide comparisons. dotplot shows the differences along with their associated confidence intervals.

See Also

resamples, diff.resamples, bwplot, densityplot, xyplot, splom

Examples

Run this code
#load(url("http://caret.r-forge.r-project.org/Classification_and_Regression_Training_files/exampleModels.RData"))

resamps <- resamples(list(CART = rpartFit,
                          CondInfTree = ctreeFit,
                          MARS = earthFit))
difs <- diff(resamps)

dotplot(difValues)

densityplot(difValues,
            metric = "RMSE",
            auto.key = TRUE,
            pch = "|")

bwplot(difValues,
       metric = "RMSE")

levelplot(difValues, what = "differences")

Run the code above in your browser using DataLab