Check for nan values before cross-matching with UCAC4