A function to return fit indices