restructuring and normalizing data files