spec.smo(x, span=3, iter=1, symmetry="even")
(0.5 * x[i-(span-1)/2] + x[i-(span-1)/2+1] +...+ x[i+(span-1)/2-1] + 0.5 * x[i+(span-1)/2] ) / (span-1))
so the smoothing window or average actually includes span points with half-weights on the ends. In the multivariate case, the same process is repeated for each column of x. span must be greater than 1 for x to be smoothed.
The Time Series chapter of the S-PLUS User's Manual.
spec.smo(x) # returns vector with ith element 0.25x(i-1)+0.5x(i)+0.25x(i+1) spec.smo(x, 3, 2) # returns vector with ith element # .0625x(i-2)+0.25x(i-1)+0.375x(i)+0.25x(i+1)+.0625x(i+2)