fixing count data save to csv