Skip to content

Commit

Permalink
docs: Update batch_run import in intro tutorial
Browse files Browse the repository at this point in the history
  • Loading branch information
EwoutH committed Sep 20, 2024
1 parent 21e3fe9 commit e4121a4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docs/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ To batch-run the model while varying, for example, the n_agents parameter, you'd
import mesa

parameters = {"n_agents": range(1, 20)}
mesa.batch_run(
mesa.batchrunner.batch_run(
MyModel,
parameters,
max_steps=10,
Expand Down
5 changes: 3 additions & 2 deletions docs/tutorials/intro_tutorial.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@
"outputs": [],
"source": [
"import mesa\n",
"from mesa.batchrunner import batch_run\n",
"from mesa.datacollection import DataCollector\n",
"\n",
"# Data visualization tools.\n",
Expand Down Expand Up @@ -1166,7 +1167,7 @@
"source": [
"params = {\"width\": 10, \"height\": 10, \"N\": range(5, 100, 5)}\n",
"\n",
"results = mesa.batch_run(\n",
"results = batch_run(\n",
" MoneyModel,\n",
" parameters=params,\n",
" iterations=7,\n",
Expand Down Expand Up @@ -1315,7 +1316,7 @@
"source": [
"params = {\"width\": 10, \"height\": 10, \"N\": [5, 10, 20, 40, 80]}\n",
"\n",
"results_5s = mesa.batch_run(\n",
"results_5s = batch_run(\n",
" MoneyModel,\n",
" parameters=params,\n",
" iterations=100,\n",
Expand Down

0 comments on commit e4121a4

Please sign in to comment.