BPTK API Documentation for the Biflow class


DataCollectors are used to collect data generated by Agents during an agent based simulation. The default data collector collects the value of each Agent property at every timestep - but you can create your own datacollects.

See the Custom Data Collectors page for details.

DataCollector Collector


A datacollector for the agent based simulation.

Collects the output data of each agent/event and makes it available to external resources such as BPTK-Py to plot the data ## DataCollector.collect_agent_statistics

collect_agent_statistics(time, agents)

Collect agent statistics from agent(s).

  • Parameters

    • time – Timestep. The timestep at which to collect agents.

    • agents – List of agent. The list of agents to collect.


record_event(time, event)

Record an event.

  • Parameters

    • time – Timestep. The time at which to record the event.

    • event – event instance The event to record.



Get the statistics collected.

  • Returns

    A dictionary with the data that was collected.