Skip to content

Commit

Permalink
Fixed Pandas warnings in test_quad.py (#738)
Browse files Browse the repository at this point in the history
  • Loading branch information
Armd04 authored Aug 30, 2024
1 parent bcba2ac commit c2ed3d6
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions quantecon/tests/test_quad.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ def setup_method(cls):
for kind in kinds:
for num in n:
num_in = num ** 2 if len(kind) == 1 else num
quad_rect_res1d.loc[func_name, num][kind] = \
quad_rect_res1d.loc[(func_name, num), kind] = \
quadrect(func, num_in, a, b, kind,
random_state=random_state)

Expand All @@ -134,10 +134,10 @@ def setup_method(cls):

for num in n:
for kind in kinds2[:4]:
data2.loc[num**2][kind] = quadrect(f1_2, [num, num],
data2.loc[num**2, kind] = quadrect(f1_2, [num, num],
a[0], b[0], kind)
for kind in kinds2[4:]:
data2.loc[num**2][kind] = quadrect(f1_2, num**2, a[0],
data2.loc[num**2, kind] = quadrect(f1_2, num**2, a[0],
b[0], kind)

cls.data2d1 = data2
Expand All @@ -149,7 +149,7 @@ def setup_method(cls):

for num in n3:
for kind in kinds2[3:]:
data3.loc[num][kind] = quadrect(f2_2, num, a[1], b[1], kind)
data3.loc[num, kind] = quadrect(f2_2, num, a[1], b[1], kind)

cls.data2d2 = data3

Expand Down

0 comments on commit c2ed3d6

Please sign in to comment.