Skip to contents

Works for agent-class.

Usage

cell(object)

cell(object) <- value

# S4 method for class 'agent'
cell(object)

# S4 method for class 'agent'
cell(object) <- value

Arguments

object

An instance of the agent-class.

value

Value with which to replace the original value of the cell slot.

See also

Examples

# Initialize agent
my_agent <- agent(center = c(0, 0), 
                  radius = 0.25, 
                  cell = 1)

# Access the cell slot for the agent
cell(my_agent)
#> tlmpw 
#>     1 

# Change the cell slot for the agent
cell(my_agent) <- 2
cell(my_agent)
#> tlmpw 
#>     2