Improved handling of data with different labels in read.demogdata()