working on building statistics.cvs from text files