changed function name so that multiple methods can be implemented
added new loess based adaptive smoothing algorithm