\HeaderA{mosaicMiss}{Mosaic plot with information about missing/imputed values}{mosaicMiss}
\keyword{hplot}{mosaicMiss}
%
\begin{Description}\relax
Create a mosaic plot with information about missing/imputed values.
\end{Description}
%
\begin{Usage}
\begin{verbatim}
mosaicMiss(x, delimiter = NULL, highlight = NULL, selection = c("any",
    "all"), plotvars = NULL, col = c("skyblue","red","orange"),
    labels = NULL, miss.labels = TRUE, ...)
\end{verbatim}
\end{Usage}
%
\begin{Arguments}
\begin{ldescription}
\item[\code{x}] a matrix or \code{data.frame}.
\item[\code{delimiter}] a character-vector to distinguish between variables
and imputation-indices for imputed variables (therefore, \code{x} needs
to have \code{\LinkA{colnames}{colnames}}). If given, it is used to determine the corresponding
imputation-index for any imputed variable (a logical-vector indicating
which values of the variable have been imputed). If such imputation-indices
are found, they are used for highlighting and the colors are adjusted 
according to the given colors for imputed variables (see \code{col}).
\item[\code{highlight}] a vector giving the variables to be used for highlighting.  
If \code{NULL} (the default), all variables are used for highlighting.
\item[\code{selection}] the selection method for highlighting missing/imputed values in 
multiple highlight variables.  Possible values are \code{"any"} 
(highlighting of missing/imputed values in \emph{any} of the highlight variables) 
and \code{"all"} (highlighting of missing/imputed values in \emph{all} of the 
highlight variables).
\item[\code{plotvars}] a vector giving the categorical variables to be plotted.  If 
\code{NULL} (the default), all variables are plotted.
\item[\code{col}] a vector of length three giving the colors to be used for observed, 
missing and imputed data. If only one color is supplied, the tiles corresponding 
to observed data are transparent and the supplied color is used for 
highlighting.
\item[\code{labels}] a list of arguments for the labeling function 
\code{\LinkA{labeling\_border}{labeling.Rul.border}}.
\item[\code{miss.labels}] either a logical indicating whether labels should be 
plotted for observed and missing/imputed (highlighted) data, or a character vector 
giving the labels.
\item[\code{...}] additional arguments to be passed to \code{\LinkA{mosaic}{mosaic}}.
\end{ldescription}
\end{Arguments}
%
\begin{Details}\relax
Mosaic plots are graphical representations of multi-way contingency tables.  
The frequencies of the different cells are visualized by area-proportional 
rectangles (tiles).  Additional tiles are be used to display the frequencies 
of missing/imputed values.  Furthermore, missing/imputed values in a certain variable or
combination of variables can be highlighted in order to explore their 
structure.
\end{Details}
%
\begin{Value}
An object of class \code{"structable"} is returned invisibly.
\end{Value}
%
\begin{Note}\relax
This function uses the highly flexible \code{strucplot} framework of package 
\code{vcd}.
\end{Note}
%
\begin{Author}\relax
Andreas Alfons, modifications by Bernd Prantner
\end{Author}
%
\begin{References}\relax
Meyer, D., Zeileis, A. and Hornik, K. (2006) The \code{strucplot} framework: 
Visualizing multi-way contingency tables with \pkg{vcd}. \emph{Journal of 
Statistical Software}, \bold{17 (3)}, 1--48.
\end{References}
%
\begin{SeeAlso}\relax
\code{\LinkA{spineMiss}{spineMiss}}, \code{\LinkA{mosaic}{mosaic}}
\end{SeeAlso}
%
\begin{Examples}
\begin{ExampleCode}
data(sleep, package = "VIM")
## for missing values
mosaicMiss(sleep, highlight = 4, 
    plotvars = 8:10, miss.labels = FALSE)

## for imputed values
mosaicMiss(kNN(sleep), highlight = 4, 
    plotvars = 8:10, delimiter = "_imp", miss.labels = FALSE)
\end{ExampleCode}
\end{Examples}
