def Simulation(fileName): chronicles = Chronicles("Test Simulation", "Eckhart Arnold", "A Test of the 'Augmented Experiment' Prototype with a simulation.") world = World(chronicles) agents = [Random() for i in range(2)] + \ [ModerateEgoist() for i in range(10)] + \ [EgoistPunisher() for i in range(10)] + \ [SimpleHeuristics() for i in range(10)] + \ [SimpleHeuristicsPunisher() for i in range(10)] world.setup(agents, PublicGoodsGame(1.6), 30, 20, 20) world.run() #report = Report(chronicles) with open(fileName, "w") as f: f.write(chronicles.toJSON())