Added fixes for CalculateYield