parses data into hash form