
socmod
implementation of an agent-based model
AgentBasedModel.Rd
This class encapsulates the model's agents, the network that structures their interactions, static or dynamic model parameters, model state, and model outputs.
Public fields
agents
Named list of agents
n_agents
Number of agents
step
Time step integer index
network
Social network that structures agent interactions
params
Model parameters for use in partner selection, interaction functions, and
output
Model output, which is either initiated or appended to depending on if the model has been run yet. Create a new agent-based model.
Methods
Method new()
Agent-based models may be initialized one of three ways: (1) by providing the agents and the social network that structures their interaction; (2) providing only the social network; or (3) provide the number of agents only, which will create and add them to a complete graph.
Usage
AgentBasedModel$new(agents = NULL, network = NULL, n_agents = NULL, ...)