Flatten labels and data.