working on appending data to file in each run in Learned_group_synchrony.c