\HeaderA{scatter.smooth}{Scatter Plot with Smooth Curve Fitted by Loess}{scatter.smooth}
\aliasA{loess.smooth}{scatter.smooth}{loess.smooth}
\keyword{smooth}{scatter.smooth}
\begin{Description}\relax
Plot and add a smooth curve computed by \code{loess} to a scatter plot.
\end{Description}
\begin{Usage}
\begin{verbatim}
scatter.smooth(x, y = NULL, span = 2/3, degree = 1,
    family = c("symmetric", "gaussian"),
    xlab = NULL, ylab = NULL,
    ylim = range(y, prediction$y, na.rm = TRUE),
    evaluation = 50, ...)

loess.smooth(x, y, span = 2/3, degree = 1,
    family = c("symmetric", "gaussian"), evaluation = 50, ...)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{x,y}] the \code{x} and \code{y} arguments provide the x and y
coordinates for the plot.  Any reasonable way of defining the
coordinates is acceptable.  See the function \code{\LinkA{xy.coords}{xy.coords}}
for details.
\item[\code{span}] smoothness parameter for \code{loess}.
\item[\code{degree}] degree of local polynomial used.
\item[\code{family}] if \code{"gaussian"} fitting is by least-squares, and if
\code{family="symmetric"} a re-descending M estimator is used.
\item[\code{xlab}] label for x axis.
\item[\code{ylab}] label for y axis.
\item[\code{ylim}] the y limits of the plot.
\item[\code{evaluation}] number of points at which to evaluate the smooth
curve.
\item[\code{...}] graphical parameters.
\end{ldescription}
\end{Arguments}
\begin{Details}\relax
\code{loess.smooth} is an auxiliary function which evaluates the
\code{loess} smooth at \code{evaluation} equally spaced points
covering the range of \code{x}.
\end{Details}
\begin{Value}
For \code{scatter.smooth}, none.

For \code{loess.smooth}, a list with two components, \code{x} (the
grid of evaluation points) and \code{y} (the smoothed values at the
grid points).
\end{Value}
\begin{SeeAlso}\relax
\code{\LinkA{loess}{loess}}
\end{SeeAlso}
\begin{Examples}
\begin{ExampleCode}
attach(cars)
scatter.smooth(speed, dist)
detach()
\end{ExampleCode}
\end{Examples}

