R> x=seq(from=0, to=pi, length.out=1000)
R> y=sin(x)
R> fit=loess(y~x)
R> predict(fit, data.frame(x=-10))
1
NA
loess by default does not extrapolate beyond the input data range. How to extrapolate for the prediction?
R> x=seq(from=0, to=pi, length.out=1000)
R> y=sin(x)
R> fit=loess(y~x)
R> predict(fit, data.frame(x=-10))
1
NA
loess by default does not extrapolate beyond the input data range. How to extrapolate for the prediction?