Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No documentation examples for using "higher-order interactions"-related functions #796

Open
jacobusmmsmit opened this issue Apr 18, 2023 · 1 comment
Assignees

Comments

@jacobusmmsmit
Copy link
Member

jacobusmmsmit commented Apr 18, 2023

Is your feature request related to a problem? Please describe.
As a game theory guy, my agents need to interact in groups, often pairwise. Currently it's not clear how to use the functions from the higher-order interactions section i.e. there are no examples in the docs of a model using it.

Particularly, it's not clear (to me) what can and can't be done with the passed function f, and it may be worth putting in another keyword to give f some arguments.

Describe the solution you'd like
Create a new docs example showcasing a very simple discrete time, nospace, evolutionary game theory model which makes use of map_agent_groups.

Describe alternatives you've considered
Perhaps we could put this in the model zoo, but given that it's documented functionality it would be nice to have an example of its use in the docs themselves.

@jacobusmmsmit
Copy link
Member Author

jacobusmmsmit commented Apr 18, 2023

When I read the docs and code for the functions in question, it seems rather that the functions I originally referred to do not do what I think they did.

In this case I would like to propose that we add functionality for users to give a pairwise_agent_step! or nwise_agent_step! function to run! or step! and a new keyword argument interaction_arity or interaction_order.

It would then look like this:

run!(game_theory_model, pairwise_step!, model_step!, steps; interaction_order = 2)

This would save users (see: me) from having to write custom higher order interaction code in their model_step! function.

One question that arises from this is that in almost all cases of higher-order interactions you would want the scheduler to be Schedulers.randomly so should it be the default in these cases? I believe it would make sense to make this the default if the interaction_order is greater than 1 and throw a warning if the scheduler is not explicitly set by the user that randomly is being used and how to change it if necessary.

I believe that the new functionality is a connected but distinct issue to the documentation part. If my understanding of the situation is correct, I think we should separate these issues and discuss them separately as, in any case, my original request for examples of using the Higher-order interactions functions remains.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant