\HeaderA{asVector}{Coerce an Object to a Vector}{asVector}
\keyword{models}{asVector}
\begin{Description}\relax
This is a generic function.  Methods for this function coerce objects
of given classes to vectors.
\end{Description}
\begin{Usage}
\begin{verbatim}
asVector(object)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{object}] An object.
\end{ldescription}
\end{Arguments}
\begin{Details}\relax
Methods for vector coercion in new classes must be created for the
\code{asVector} generic instead of \code{as.vector}.  The
\code{as.vector} function is internal and not easily extended.
Currently the only class with an \code{asVector} method is the
\code{xyVector} class.
\end{Details}
\begin{Value}
a vector
\end{Value}
\begin{Author}\relax
Douglas Bates and Bill Venables
\end{Author}
\begin{SeeAlso}\relax
\code{\LinkA{xyVector}{xyVector}}
\end{SeeAlso}
\begin{Examples}
\begin{ExampleCode}
ispl <- interpSpline( weight ~ height,  women )
pred <- predict(ispl)
class(pred)
utils::str(pred)
asVector(pred)
\end{ExampleCode}
\end{Examples}

