add function datatocopus to change raw data to corpus