update for NANs, comply with REP117