convert data and naming to text files