Skip to content

DOC: Updated to mention axis='index' and axis='columns #10202

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 25, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 21 additions & 21 deletions pandas/core/frame.py
Original file line number Diff line number Diff line change
Expand Up @@ -2745,7 +2745,7 @@ def dropna(self, axis=0, how='any', thresh=None, subset=None,

Parameters
----------
axis : {0, 1}, or tuple/list thereof
axis : {0 or 'index', 1 or 'columns'}, or tuple/list thereof
Pass tuple or list to drop on multiple axes
how : {'any', 'all'}
* any : if any NA values are present, drop that label
Expand Down Expand Up @@ -2890,7 +2890,7 @@ def sort(self, columns=None, axis=0, ascending=True,
ascending : boolean or list, default True
Sort ascending vs. descending. Specify list for multiple sort
orders
axis : {0, 1}
axis : {0 or 'index', 1 or 'columns'}, default 0
Sort index/rows versus columns
inplace : boolean, default False
Sort the DataFrame without creating a new instance
Expand Down Expand Up @@ -2919,7 +2919,7 @@ def sort_index(self, axis=0, by=None, ascending=True, inplace=False,

Parameters
----------
axis : {0, 1}
axis : {0 or 'index', 1 or 'columns'}, default 0
Sort index/rows versus columns
by : object
Column name(s) in frame. Accepts a column name or a list
Expand Down Expand Up @@ -3027,7 +3027,7 @@ def sortlevel(self, level=0, axis=0, ascending=True,
Parameters
----------
level : int
axis : {0, 1}
axis : {0 or 'index', 1 or 'columns'}, default 0
ascending : boolean, default True
inplace : boolean, default False
Sort the DataFrame without creating a new instance
Expand Down Expand Up @@ -3639,9 +3639,9 @@ def apply(self, func, axis=0, broadcast=False, raw=False, reduce=None,
----------
func : function
Function to apply to each column/row
axis : {0, 1}
* 0 : apply function to each column
* 1 : apply function to each row
axis : {0 or 'index', 1 or 'columns'}, default 0
* 0 or 'index': apply function to each column
* 1 or 'columns': apply function to each row
broadcast : boolean, default False
For aggregation functions, return object of same size with values
propagated
Expand Down Expand Up @@ -4162,8 +4162,8 @@ def corrwith(self, other, axis=0, drop=False):
Parameters
----------
other : DataFrame
axis : {0, 1}
0 to compute column-wise, 1 for row-wise
axis : {0 or 'index', 1 or 'columns'}, default 0
0 or 'index' to compute column-wise, 1 or 'columns' for row-wise
drop : boolean, default False
Drop missing indices from result, default returns union of all

Expand Down Expand Up @@ -4214,8 +4214,8 @@ def count(self, axis=0, level=None, numeric_only=False):

Parameters
----------
axis : {0, 1}
0 for row-wise, 1 for column-wise
axis : {0 or 'index', 1 or 'columns'}, default 0
0 or 'index' for row-wise, 1 or 'columns' for column-wise
level : int or level name, default None
If the axis is a MultiIndex (hierarchical), count along a
particular level, collapsing into a DataFrame
Expand Down Expand Up @@ -4368,8 +4368,8 @@ def idxmin(self, axis=0, skipna=True):

Parameters
----------
axis : {0, 1}
0 for row-wise, 1 for column-wise
axis : {0 or 'index', 1 or 'columns'}, default 0
0 or 'index' for row-wise, 1 or 'columns' for column-wise
skipna : boolean, default True
Exclude NA/null values. If an entire row/column is NA, the result
will be NA
Expand Down Expand Up @@ -4399,8 +4399,8 @@ def idxmax(self, axis=0, skipna=True):

Parameters
----------
axis : {0, 1}
0 for row-wise, 1 for column-wise
axis : {0 or 'index', 1 or 'columns'}, default 0
0 or 'index' for row-wise, 1 or 'columns' for column-wise
skipna : boolean, default True
Exclude NA/null values. If an entire row/column is NA, the result
will be first index.
Expand Down Expand Up @@ -4446,9 +4446,9 @@ def mode(self, axis=0, numeric_only=False):

Parameters
----------
axis : {0, 1, 'index', 'columns'} (default 0)
* 0/'index' : get mode of each column
* 1/'columns' : get mode of each row
axis : {0 or 'index', 1 or 'columns'}, default 0
* 0 or 'index' : get mode of each column
* 1 or 'columns' : get mode of each row
numeric_only : boolean, default False
if True, only apply to numeric columns

Expand Down Expand Up @@ -4553,7 +4553,7 @@ def rank(self, axis=0, numeric_only=None, method='average',

Parameters
----------
axis : {0, 1}, default 0
axis : {0 or 'index', 1 or 'columns'}, default 0
Ranks over columns (0) or rows (1)
numeric_only : boolean, default None
Include only float, int, boolean data
Expand Down Expand Up @@ -4605,7 +4605,7 @@ def to_timestamp(self, freq=None, how='start', axis=0, copy=True):
how : {'s', 'e', 'start', 'end'}
Convention for converting period to timestamp; start of period
vs. end
axis : {0, 1} default 0
axis : {0 or 'index', 1 or 'columns'}, default 0
The axis to convert (the index by default)
copy : boolean, default True
If false then underlying input data is not copied
Expand Down Expand Up @@ -4636,7 +4636,7 @@ def to_period(self, freq=None, axis=0, copy=True):
Parameters
----------
freq : string, default
axis : {0, 1}, default 0
axis : {0 or 'index', 1 or 'columns'}, default 0
The axis to convert (the index by default)
copy : boolean, default True
If False then underlying input data is not copied
Expand Down