changed handling of missing values