py how to drop np.nan from list code example Example: remove nan from list python cleanedList = [x for x in countries if str(x) != 'nan']