1\name{sm.autoregression} 2\alias{sm.autoregression} 3\title{ 4Nonparametric estimation of the autoregression function 5} 6\description{ 7This function estimates nonparametrically the autoregression function 8(conditional mean given the past values) of a time series \code{x}, 9assumed to be stationary. 10} 11\usage{ 12sm.autoregression(x, h = hnorm(x), d = 1, maxlag = d, lags, 13 se = FALSE, ask = TRUE) 14} 15\arguments{ 16\item{x}{ 17vector containing the time series values. 18} 19\item{h}{ 20the bandwidth used for kernel smoothing. 21} 22\item{d}{ 23number of past observations used for conditioning; it must be 1 24(default value) or 2. 25} 26\item{maxlag}{ 27maximum of the lagged values to be considered (default value is \code{d}). 28} 29\item{lags}{ 30if \code{d==1}, this is a vector containing the lags considered for conditioning; 31if \code{d==2}, this is a matrix with two columns, whose rows contains pair of 32values considered for conditioning. 33} 34\item{se}{ 35if \code{se==T}, pointwise confidence bands are computed of approximate level 95\%. 36} 37\item{ask}{ 38if \code{ask==TRUE}, the program pauses after each plot until <Enter> is pressed. 39} 40} 41\value{ 42a list with the outcome of the final estimation (corresponding to 43the last value or pairs of values of lags), as returned by \code{sm.regression}. 44} 45\section{Side Effects}{ 46graphical output is produced on the current device. 47} 48\details{ 49see Section 7.3 of the reference below. 50} 51\references{ 52Bowman, A.W. and Azzalini, A. (1997). 53\emph{Applied Smoothing Techniques for Data Analysis: } 54\emph{the Kernel Approach with S-Plus Illustrations.} 55Oxford University Press, Oxford. 56} 57\seealso{ 58\code{\link{sm.regression}}, \code{\link{sm.ts.pdf}} 59} 60\examples{ 61sm.autoregression(log(lynx), maxlag=3, se=TRUE) 62sm.autoregression(log(lynx), lags=cbind(2:3,4:5)) 63} 64\keyword{nonparametric} 65\keyword{smooth} 66\keyword{ts} 67% Converted by Sd2Rd version 1.15. 68