getID: Get the ID of the agent.

View source: R/RcppExports.R

getIDR Documentation

Get the ID of the agent.

Description

Get the ID of the agent.

Arguments

agent

an external pointer returned by newAgent

Details

Before an agent is added to a population, its id is 0. After it is added, its id is the index in the population (starting from 1).

If agent is an R6 object, then we should either use agent$id, or use getID(agent$get)

Value

an integer value


ABM documentation built on April 4, 2025, 1:44 a.m.