close
The Wayback Machine - https://web.archive.org/web/20200914133911/https://github.com/topics/agent-based-modeling
Skip to content
#

agent-based-modeling

Here are 365 public repositories matching this topic...

TheBizzle
TheBizzle commented Apr 30, 2018

Steps to reproduce:

  • Open Wolf Sheep Predation
  • Open the plot and note that "wolves" is a line plot
  • Run set-current-plot-pen "wolves"
  • Run set-plot-pen-mode 1 ; bar mode
  • Open the plot again and check the mode of "wolves"; it will still say "Line"
  • As a sanity check, feel free to plot as many points as you want with these settings, while noting that the mode stays "L
pitmonticone
pitmonticone commented Sep 12, 2020
g = model.space.graph

weight_matrix = LightGraphs.weights(g)
for i in 1:nv(g)
	weight_matrix[i,i] = 0
end

edgewidthsdict = Dict()
for node in 1:nv(g)
	nbs = neighbors(g,node)
	for nb in nbs
		edgewidthsdict[(node,nb)] = weight_matrix[node,nb] / sum([outneighbor for outneighbor in weight_matrix[node,:]])
	end
end

edgewidthsf(s,d,w) = edgewidthsdict[(s,d)]*5

plotargs =
graph-theory

Julia and Python complex system applications in ecology, epidemiology, sociology, economics & finance; network science models including Erdős-Rényi & Barabási-Albert; graph theory algorithms involving Gillespie, Bron Kerbosch, Bellman Ford, A*, Kruskal, Borůvka, Prim, Dijkstra, Topological Sort, DFS, BFS

  • Updated Jul 3, 2020
  • Jupyter Notebook

Improve this page

Add a description, image, and links to the agent-based-modeling topic page so that developers can more easily learn about it.

Curate this topic

Add this topic to your repo

To associate your repository with the agent-based-modeling topic, visit your repo's landing page and select "manage topics."

Learn more

You can’t perform that action at this time.