update to incorporate loess smoothing