moved smooth.R to ./R