add polynomial fit logic