Counting agents passed through the block

To know the number of agents that passed through the flowchart block, you should use the function count() of the corresponding port of the block. For example, if you have source block and want to know how many agents left its output port out, type: source.out.count()

To know the name of the block's port, please refer to the description of the block in the Library Reference Guide. The names of the block ports are shown on the block figure at the top of the page:

Statistics on agent throughput

AnyLogic also displays statistics on agent throughput through the flowchart blocks at the model runtime by displaying text labels with some stats near block icons.

To enable the display of counters, click the small triangle in the upper left or right corner of the block:

You can totally switch on/off all the counters in the AnyLogic Preferences.