Suggestions from @DavidPS incorporated