GGPlot the Mean Square Error with Error Bar for +/- 1 Standard Error

ggcv(
  cv.obj,
  title = "MSE for CV of monothetic clustering",
  xlab = "Number of clusters",
  ylab = "MSE +/- 1 SE",
  type = c("b", "p", "l"),
  linetype = 2,
  err.col = "red",
  err.width = 0.2
)

Arguments

cv.obj

A cv.MonoClust object (output of cv.test()).

title

Overall title for the plot.

xlab

Title for x axis.

ylab

Title for y axis.

type

What type of plot should be drawn. Choosing between "l" (line only), "p" (point only), and "b" (both line and point).

linetype

The line type. See vignette("ggplot2-specs").

err.col

Color of the error bars.

err.width

Width of the bars.

Value

A ggplot2 object.

See also

Plot using base R plot.cv.MonoClust()

Examples

# \donttest{ library(cluster) data(ruspini) # 10-fold cross-validation cptable <- cv.test(ruspini, minnodes = 2, maxnodes = 4) ggcv(cptable)
# }