rename variable 'NM' to 'NAME'