Test for Nans before changing them to minimum dataset value