cellwiseheatmap | R Documentation |
Makes a heatmap of cellwise outliers.
cellwiseheatmap(cellwiseoutliers, data,
col = c("blue", "lightgray", "red"), col.scale.factor = 1,
notecol.outlier = "white", notecol.clean = "black", notecex = 1,
margins = c(9.5, 14), lhei = c(0.5, 15), lwid = c(0.1, 3.5),
sepcolor = "white", sepwidth = c(0.01, 0.01))
cellwiseoutliers |
a matrix that indicates the cellwise outliers as the (scaled) difference between the original data and imputed data, both scaled and centered. Typically the result of a call to the |
data |
the data as a data frame that is shown in the cells, including row and column names. |
col |
vector of colors used for downward outliers, clean cells and upward outliers respectively (default is |
col.scale.factor |
numeric factor for scaling the colors of the cells (default is |
notecol.outlier |
character string specifying the color for cellnote text of cellwise outliers (default is |
notecol.clean |
character string specifying the color for cellnote text of clean cells (default is |
notecex |
numeric scaling factor for cellnotes (default is |
margins |
numeric vector of length 2 containing the margins (see |
lhei |
numeric vector of length 2 containing the row height (default is |
lwid |
numeric vector of length 2 containing the row width (default is |
sepcolor |
character string specifying the color between the cells (default is |
sepwidth |
vector of length 2 giving the width and height of the separator box drawn between the cells (default is |
cellwiseheatmap
plots a heatmap of cellwise outliers which are typically
the result of a call to the crm
function.
Peter Filzmoser, Sebastiaan Hoppner, Irene Ortner, Sven Serneels, and Tim Verdonck
Filzmoser, P., Hoppner, S., Ortner, I., Serneels, S., and Verdonck, T. (2020). Cellwise Robust M regression. Computational Statistics and Data Analysis, 147, 106944. DOI:10.1016/j.csda.2020.106944
crm
, spadimo
, predict.crm
, daprpr
library(crmReg)
data(topgear)
# fit Cellwise Robust M-regression:
crmfit <- crm(formula = MPG ~ ., data = topgear)
# cellwise heatmap of casewise outliers:
cellwiseheatmap(cellwiseoutliers = crmfit$cellwiseoutliers[which(crmfit$casewiseoutliers), ],
data = round(topgear[which(crmfit$casewiseoutliers), -7], 2),
col.scale.factor = 1/4)
# check the plotted heatmap!
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.