From d58c4fe1dbfa45603182b58590daa064aa31411e Mon Sep 17 00:00:00 2001 From: 4bic Date: Fri, 9 Mar 2018 16:32:13 +0300 Subject: [PATCH 1/4] fixed 'Wrong parameter order' validation error --- pandas/core/ops.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pandas/core/ops.py b/pandas/core/ops.py index 931e91b941a7e..296c5c425e1cd 100644 --- a/pandas/core/ops.py +++ b/pandas/core/ops.py @@ -513,14 +513,14 @@ def _get_op_name(op, special): other : Series, DataFrame, or constant axis : {{0, 1, 'index', 'columns'}} For Series input, axis to match Series index on +level : int or name + Broadcast across a level, matching Index values on the + passed MultiIndex level fill_value : None or float value, default None Fill existing missing (NaN) values, and any new element needed for successful DataFrame alignment, with this value before computation. If data in both corresponding DataFrame locations is missing the result will be missing -level : int or name - Broadcast across a level, matching Index values on the - passed MultiIndex level Notes ----- From 736972df75a7d230355b49eb3e3d7d21eb286a36 Mon Sep 17 00:00:00 2001 From: 4bic Date: Fri, 9 Mar 2018 17:35:39 +0300 Subject: [PATCH 2/4] =?UTF-8?q?added=20use=20of=20=E2=80=98=E2=80=A6?= =?UTF-8?q?=E2=80=99=20to=20pass=20doctests?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pandas/core/ops.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pandas/core/ops.py b/pandas/core/ops.py index 296c5c425e1cd..ffad0c73a543b 100644 --- a/pandas/core/ops.py +++ b/pandas/core/ops.py @@ -477,7 +477,7 @@ def _get_op_name(op, special): Examples -------- >>> a = pd.DataFrame([1, 1, 1, np.nan], index=['a', 'b', 'c', 'd'], - columns=['one']) +... columns=['one']) >>> a one a 1.0 @@ -485,8 +485,8 @@ def _get_op_name(op, special): c 1.0 d NaN >>> b = pd.DataFrame(dict(one=[1, np.nan, 1, np.nan], - two=[np.nan, 2, np.nan, 2]), - index=['a', 'b', 'd', 'e']) +... two=[np.nan, 2, np.nan, 2]), +... index=['a', 'b', 'd', 'e']) >>> b one two a 1.0 NaN @@ -533,7 +533,7 @@ def _get_op_name(op, special): Examples -------- >>> a = pd.DataFrame([1, 1, 1, np.nan], index=['a', 'b', 'c', 'd'], - columns=['one']) +... columns=['one']) >>> a one a 1.0 @@ -541,8 +541,8 @@ def _get_op_name(op, special): c 1.0 d NaN >>> b = pd.DataFrame(dict(one=[1, np.nan, 1, np.nan], - two=[np.nan, 2, np.nan, 2]), - index=['a', 'b', 'd', 'e']) +... two=[np.nan, 2, np.nan, 2]), +... index=['a', 'b', 'd', 'e']) >>> b one two a 1.0 NaN From 2e3606803658a2e865f10ee9363a8c3602a23b9f Mon Sep 17 00:00:00 2001 From: 4bic Date: Fri, 9 Mar 2018 22:01:18 +0300 Subject: [PATCH 3/4] adjustment to indentation --- pandas/core/ops.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pandas/core/ops.py b/pandas/core/ops.py index ffad0c73a543b..c8635c07dfa53 100644 --- a/pandas/core/ops.py +++ b/pandas/core/ops.py @@ -542,7 +542,7 @@ def _get_op_name(op, special): d NaN >>> b = pd.DataFrame(dict(one=[1, np.nan, 1, np.nan], ... two=[np.nan, 2, np.nan, 2]), -... index=['a', 'b', 'd', 'e']) +... index=['a', 'b', 'd', 'e']) >>> b one two a 1.0 NaN From ca3e5f9ca8e73f43dc71be260412e7cbf7d2d644 Mon Sep 17 00:00:00 2001 From: Joris Van den Bossche Date: Thu, 15 Mar 2018 14:47:06 +0100 Subject: [PATCH 4/4] fix alignment --- pandas/core/ops.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pandas/core/ops.py b/pandas/core/ops.py index 1065d003e1414..037c9e31f7157 100644 --- a/pandas/core/ops.py +++ b/pandas/core/ops.py @@ -354,7 +354,7 @@ def _get_op_name(op, special): d NaN >>> b = pd.DataFrame(dict(one=[1, np.nan, 1, np.nan], ... two=[np.nan, 2, np.nan, 2]), -... index=['a', 'b', 'd', 'e']) +... index=['a', 'b', 'd', 'e']) >>> b one two a 1.0 NaN @@ -529,7 +529,7 @@ def _get_op_name(op, special): d NaN >>> b = pd.DataFrame(dict(one=[1, np.nan, 1, np.nan], ... two=[np.nan, 2, np.nan, 2]), -... index=['a', 'b', 'd', 'e']) +... index=['a', 'b', 'd', 'e']) >>> b one two a 1.0 NaN