Commit
·
35908ef
1
Parent(s):
b375ca6
Update multi_agent_2D.py
Browse files- multi_agent_2D.py +2 -2
multi_agent_2D.py
CHANGED
@@ -74,7 +74,7 @@ def multi_agent_walk(agent_count, iters, step_size = 1, random_seed = None):
|
|
74 |
random_numbers = [random.randint(0,100000) for _ in range(agent_count)]
|
75 |
|
76 |
|
77 |
-
fig, ax = plt.subplots(figsize=(
|
78 |
color_list = []
|
79 |
|
80 |
for i in range(agent_count):
|
@@ -106,7 +106,7 @@ def multi_agent_walk(agent_count, iters, step_size = 1, random_seed = None):
|
|
106 |
legend_df = pd.DataFrame({'#':agent_number, 'dis.':displacement, 'End Point':end_point, })
|
107 |
info_box = legend_df.to_string(index=False)
|
108 |
|
109 |
-
ax.text(
|
110 |
transform=ax.transAxes,
|
111 |
verticalalignment='top',
|
112 |
bbox=dict(boxstyle='round', facecolor='white', alpha=0.5)
|
|
|
74 |
random_numbers = [random.randint(0,100000) for _ in range(agent_count)]
|
75 |
|
76 |
|
77 |
+
fig, ax = plt.subplots(figsize=(8,8))
|
78 |
color_list = []
|
79 |
|
80 |
for i in range(agent_count):
|
|
|
106 |
legend_df = pd.DataFrame({'#':agent_number, 'dis.':displacement, 'End Point':end_point, })
|
107 |
info_box = legend_df.to_string(index=False)
|
108 |
|
109 |
+
ax.text(0.01, 0.99, info_box,
|
110 |
transform=ax.transAxes,
|
111 |
verticalalignment='top',
|
112 |
bbox=dict(boxstyle='round', facecolor='white', alpha=0.5)
|