From: Douglas N. <pet...@gm...> - 2009-07-28 20:23:02
|
I'm trying to do this: public double getNumAgentsX() { return numAgentsX } public void buildSchedule(){ schedule.scheduleActionBeginning(0, new BasicAction() { public void execute() { recorder.record(); } }); schedule.scheduleActionAtEnd(recorder, "writeToFile"); } public void buildModel() { recorder = new DataRecorder("./data.txt", this); recorder.createNumericDataSource("numAgentsX", this, "getNumAgentsX"); ... } It has to record the variable numAgentsX each step. It record zero, the value that is in the setup(), not the value along the simulation that changes in method step(). Im using RepastJ 3. Does anybody know what im doing wrong? --- Doug |