\HeaderA{rtrend}{REMOVE LINEAR TREND OR MEAN}{rtrend}
\aliasA{rmean}{rtrend}{rmean}
\begin{Description}\relax
Removes the linear trend or mean from SAC data.
Note that defailt of "spect" is to detrend
because that is the default for
\code{\LinkA{spec.pgram}{spec.pgram}} (see example below).
\end{Description}
\begin{Usage}
\begin{verbatim}
rtrend(x)
rmean(x)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{x}] an object of class \code{"rsac"}.
\end{ldescription}
\end{Arguments}
\begin{Value}
same as input.
\end{Value}
\begin{Author}\relax
Eric M. Thompson \textless{}eric.thompson@tufts.edu\textgreater{}
\end{Author}
\begin{Examples}
\begin{ExampleCode}

x <- rsac.skeleton(1)
x[[1]]$amp <- runif(1e3) 
x[[1]]$dt <- 1

plot(x)

# DC offset:
spect(x, detrend = FALSE)

# Default detrends, removing DC:
spect(x)

\end{ExampleCode}
\end{Examples}

