Added function FitSecondary