Skip to content

Commit 5e8b130

Browse files
committed
Revert disambiguating underscores
1 parent 717a12a commit 5e8b130

File tree

1 file changed

+11
-13
lines changed

1 file changed

+11
-13
lines changed

pandas/tests/frame/test_analytics.py

+11-13
Original file line numberDiff line numberDiff line change
@@ -91,19 +91,18 @@ def wrapper(x):
9191
tm.assert_series_equal(r1, expected)
9292

9393

94-
# underscores added to distinguish argument names from fixture names
95-
def assert_stat_op_api(opname, float_frame_, float_string_frame_,
94+
def assert_stat_op_api(opname, float_frame, float_string_frame,
9695
has_numeric_only=False):
9796

9897
# make sure works on mixed-type frame
99-
getattr(float_string_frame_, opname)(axis=0)
100-
getattr(float_string_frame_, opname)(axis=1)
98+
getattr(float_string_frame, opname)(axis=0)
99+
getattr(float_string_frame, opname)(axis=1)
101100

102101
if has_numeric_only:
103-
getattr(float_string_frame_, opname)(axis=0, numeric_only=True)
104-
getattr(float_string_frame_, opname)(axis=1, numeric_only=True)
105-
getattr(float_frame_, opname)(axis=0, numeric_only=False)
106-
getattr(float_frame_, opname)(axis=1, numeric_only=False)
102+
getattr(float_string_frame, opname)(axis=0, numeric_only=True)
103+
getattr(float_string_frame, opname)(axis=1, numeric_only=True)
104+
getattr(float_frame, opname)(axis=0, numeric_only=False)
105+
getattr(float_frame, opname)(axis=1, numeric_only=False)
107106

108107

109108
def assert_bool_op_calc(opname, alternative, main_frame, has_skipna=True):
@@ -149,11 +148,10 @@ def wrapper(x):
149148
assert r1.all()
150149

151150

152-
# underscores added to distinguish argument names from fixture names
153-
def assert_bool_op_api(opname, bool_frame_with_na_, float_string_frame_,
151+
def assert_bool_op_api(opname, bool_frame_with_na, float_string_frame,
154152
has_bool_only=False):
155153
# make sure op works on mixed-type frame
156-
mixed = float_string_frame_
154+
mixed = float_string_frame
157155
mixed['_bool_'] = np.random.randn(len(mixed)) > 0.5
158156
getattr(mixed, opname)(axis=0)
159157
getattr(mixed, opname)(axis=1)
@@ -168,8 +166,8 @@ def __nonzero__(self):
168166
if has_bool_only:
169167
getattr(mixed, opname)(axis=0, bool_only=True)
170168
getattr(mixed, opname)(axis=1, bool_only=True)
171-
getattr(bool_frame_with_na_, opname)(axis=0, bool_only=False)
172-
getattr(bool_frame_with_na_, opname)(axis=1, bool_only=False)
169+
getattr(bool_frame_with_na, opname)(axis=0, bool_only=False)
170+
getattr(bool_frame_with_na, opname)(axis=1, bool_only=False)
173171

174172

175173
class TestDataFrameAnalytics():

0 commit comments

Comments
 (0)