\HeaderA{noquote}{Class for ``no quote'' Printing of Character Strings}{noquote}
\aliasA{as.matrix.noquote}{noquote}{as.matrix.noquote}
\aliasA{c.noquote}{noquote}{c.noquote}
\aliasA{print.noquote}{noquote}{print.noquote}
\aliasA{[.noquote}{noquote}{[.noquote}
\keyword{print}{noquote}
\keyword{methods}{noquote}
\keyword{utilities}{noquote}
\begin{Description}\relax
Print character strings without quotes.
\end{Description}
\begin{Usage}
\begin{verbatim}
noquote(obj)

## S3 method for class 'noquote':
print(x, ...)

## S3 method for class 'noquote':
c(..., recursive = FALSE)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{obj}] any \R{} object, typically a vector of
\code{\LinkA{character}{character}} strings.
\item[\code{x}] an object of class \code{"noquote"}.
\item[\code{...}] further options passed to next methods, such as \code{\LinkA{print}{print}}.
\item[\code{recursive}] for compatibility with the generic \code{\LinkA{c}{c}} function.
\end{ldescription}
\end{Arguments}
\begin{Details}\relax
\code{noquote} returns its argument as an object of class
\code{"noquote"}.  There is a method for \code{c()} and subscript
method (\code{"[.noquote"}) which ensures that the class is not lost
by subsetting.  The print method (\code{print.noquote}) prints
character strings \emph{without} quotes (\code{"..."}).

These functions exist both as utilities and as an example of using (S3)
\code{\LinkA{class}{class}} and object orientation.
\end{Details}
\begin{Author}\relax
Martin Maechler \email{maechler@stat.math.ethz.ch}
\end{Author}
\begin{SeeAlso}\relax
\code{\LinkA{methods}{methods}},
\code{\LinkA{class}{class}},
\code{\LinkA{print}{print}}.
\end{SeeAlso}
\begin{Examples}
\begin{ExampleCode}
letters
nql <- noquote(letters)
nql
nql[1:4] <- "oh"
nql[1:12]

cmp.logical <- function(log.v)
{
  ## Purpose: compact printing of logicals
  log.v <- as.logical(log.v)
  noquote(if(length(log.v)==0)"()" else c(".","|")[1+log.v])
}
cmp.logical(stats::runif(20) > 0.8)
\end{ExampleCode}
\end{Examples}

