Skip to content

Best way to have parameters changing over time #2758

Answered by colinfrisch
dylan-munson asked this question in Q&A
Discussion options

You must be logged in to vote

Hey, a simple way that you could do this would be to use the model.steps() attribute : it gives you access to the current step of the model, and simply make an if condition with this.
If you want to access the steps in your agent class, you can simply use agent.model.steps() !
You can check out the precise model documentation at https://mesa.readthedocs.io/latest/apis/model.html#mesa.model.Model

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by colinfrisch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants