bug fixes, added R methods to trend fitter