Handle missing values better