Skip to content

Commit b2734ee

Browse files
HughKelleyWillAyd
authored andcommitted
Pr09 batch 1 (#29324)
1 parent 75410f8 commit b2734ee

File tree

11 files changed

+27
-27
lines changed

11 files changed

+27
-27
lines changed

pandas/core/computation/eval.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,7 @@ def eval(
219219
More backends may be available in the future.
220220
221221
truediv : bool, optional
222-
Whether to use true division, like in Python >= 3
222+
Whether to use true division, like in Python >= 3.
223223
local_dict : dict or None, optional
224224
A dictionary of local variables, taken from locals() by default.
225225
global_dict : dict or None, optional

pandas/core/indexes/datetimes.py

+6-6
Original file line numberDiff line numberDiff line change
@@ -103,13 +103,13 @@ class DatetimeIndex(DatetimeIndexOpsMixin, Int64Index, DatetimeDelegateMixin):
103103
Parameters
104104
----------
105105
data : array-like (1-dimensional), optional
106-
Optional datetime-like data to construct index with
106+
Optional datetime-like data to construct index with.
107107
copy : bool
108-
Make a copy of input ndarray
108+
Make a copy of input ndarray.
109109
freq : str or pandas offset object, optional
110110
One of pandas date offset strings or corresponding objects. The string
111111
'infer' can be passed in order to set the frequency of the index as the
112-
inferred frequency upon creation
112+
inferred frequency upon creation.
113113
114114
start : starting value, datetime-like, optional
115115
If data is None, start is used as the start point in generating regular
@@ -119,19 +119,19 @@ class DatetimeIndex(DatetimeIndexOpsMixin, Int64Index, DatetimeDelegateMixin):
119119
120120
periods : int, optional, > 0
121121
Number of periods to generate, if generating index. Takes precedence
122-
over end argument
122+
over end argument.
123123
124124
.. deprecated:: 0.24.0
125125
126126
end : end time, datetime-like, optional
127127
If periods is none, generated index will extend to first conforming
128-
time on or just past end argument
128+
time on or just past end argument.
129129
130130
.. deprecated:: 0.24.0
131131
132132
closed : str or None, default None
133133
Make the interval closed with respect to the given frequency to
134-
the 'left', 'right', or both sides (None)
134+
the 'left', 'right', or both sides (None).
135135
136136
.. deprecated:: 0.24. 0
137137

pandas/core/indexes/multi.py

+8-8
Original file line numberDiff line numberDiff line change
@@ -882,13 +882,13 @@ def set_codes(self, codes, level=None, inplace=False, verify_integrity=True):
882882
Parameters
883883
----------
884884
codes : sequence or list of sequence
885-
new codes to apply
885+
New codes to apply.
886886
level : int, level name, or sequence of int/level names (default None)
887-
level(s) to set (None for all levels)
887+
Level(s) to set (None for all levels).
888888
inplace : bool
889-
if True, mutates in place
889+
If True, mutates in place.
890890
verify_integrity : bool (default True)
891-
if True, checks that levels and codes are compatible
891+
If True, checks that levels and codes are compatible.
892892
893893
Returns
894894
-------
@@ -1717,7 +1717,7 @@ def to_hierarchical(self, n_repeat, n_shuffle=1):
17171717
Parameters
17181718
----------
17191719
n_repeat : int
1720-
Number of times to repeat the labels on self
1720+
Number of times to repeat the labels on self.
17211721
n_shuffle : int
17221722
Controls the reordering of the labels. If the result is going
17231723
to be an inner level in a MultiIndex, n_shuffle will need to be
@@ -2335,11 +2335,11 @@ def sortlevel(self, level=0, ascending=True, sort_remaining=True):
23352335
Parameters
23362336
----------
23372337
level : list-like, int or str, default 0
2338-
If a string is given, must be a name of the level
2338+
If a string is given, must be a name of the level.
23392339
If list-like must be names or ints of levels.
23402340
ascending : bool, default True
2341-
False to sort in descending order
2342-
Can also be a list to specify a directed ordering
2341+
False to sort in descending order.
2342+
Can also be a list to specify a directed ordering.
23432343
sort_remaining : sort by the remaining levels after level
23442344
23452345
Returns

pandas/core/reshape/merge.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ def merge_asof(
359359
- If True, allow matching with the same 'on' value
360360
(i.e. less-than-or-equal-to / greater-than-or-equal-to)
361361
- If False, don't match the same 'on' value
362-
(i.e., strictly less-than / strictly greater-than)
362+
(i.e., strictly less-than / strictly greater-than).
363363
364364
direction : 'backward' (default), 'forward', or 'nearest'
365365
Whether to search for prior, subsequent, or closest matches.

pandas/core/reshape/tile.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ def qcut(x, q, labels=None, retbins=False, precision=3, duplicates="raise"):
296296
Whether to return the (bins, labels) or not. Can be useful if bins
297297
is given as a scalar.
298298
precision : int, optional
299-
The precision at which to store and display the bins labels
299+
The precision at which to store and display the bins labels.
300300
duplicates : {default 'raise', 'drop'}, optional
301301
If bin edges are not unique, raise ValueError or drop non-uniques.
302302

pandas/core/tools/numeric.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ def to_numeric(arg, errors="raise", downcast=None):
3636
----------
3737
arg : scalar, list, tuple, 1-d array, or Series
3838
errors : {'ignore', 'raise', 'coerce'}, default 'raise'
39-
- If 'raise', then invalid parsing will raise an exception
40-
- If 'coerce', then invalid parsing will be set as NaN
41-
- If 'ignore', then invalid parsing will return the input
39+
- If 'raise', then invalid parsing will raise an exception.
40+
- If 'coerce', then invalid parsing will be set as NaN.
41+
- If 'ignore', then invalid parsing will return the input.
4242
downcast : {'integer', 'signed', 'unsigned', 'float'}, default None
4343
If not None, and if the data has been successfully cast to a
4444
numerical dtype (or if the data was numeric to begin with),

pandas/io/excel/_base.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -552,9 +552,9 @@ class ExcelWriter(metaclass=abc.ABCMeta):
552552
``io.excel.<extension>.writer``. NOTE: can only be passed as a keyword
553553
argument.
554554
date_format : str, default None
555-
Format string for dates written into Excel files (e.g. 'YYYY-MM-DD')
555+
Format string for dates written into Excel files (e.g. 'YYYY-MM-DD').
556556
datetime_format : str, default None
557-
Format string for datetime objects written into Excel files
557+
Format string for datetime objects written into Excel files.
558558
(e.g. 'YYYY-MM-DD HH:MM:SS')
559559
mode : {'w', 'a'}, default 'w'
560560
File mode to use (write or append).

pandas/io/pytables.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1024,7 +1024,7 @@ def append(
10241024
table(t) : table format
10251025
Write as a PyTables Table structure which may perform
10261026
worse but allow more flexible operations like searching
1027-
/ selecting subsets of the data
1027+
/ selecting subsets of the data.
10281028
append : bool, default True
10291029
Append the input data to the existing.
10301030
data_columns : list of columns, or True, default None

pandas/io/spss.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ def read_spss(
2020
Parameters
2121
----------
2222
path : string or Path
23-
File path
23+
File path.
2424
usecols : list-like, optional
2525
Return a subset of the columns. If None, return all columns.
2626
convert_categoricals : bool, default is True

pandas/io/sql.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ def read_sql_query(
294294
to pass parameters is database driver dependent. Check your
295295
database driver documentation for which of the five syntax styles,
296296
described in PEP 249's paramstyle, is supported.
297-
Eg. for psycopg2, uses %(name)s so use params={'name' : 'value'}
297+
Eg. for psycopg2, uses %(name)s so use params={'name' : 'value'}.
298298
parse_dates : list or dict, default: None
299299
- List of column names to parse as dates.
300300
- Dict of ``{column_name: format string}`` where format string is
@@ -372,7 +372,7 @@ def read_sql(
372372
to pass parameters is database driver dependent. Check your
373373
database driver documentation for which of the five syntax styles,
374374
described in PEP 249's paramstyle, is supported.
375-
Eg. for psycopg2, uses %(name)s so use params={'name' : 'value'}
375+
Eg. for psycopg2, uses %(name)s so use params={'name' : 'value'}.
376376
parse_dates : list or dict, default: None
377377
- List of column names to parse as dates.
378378
- Dict of ``{column_name: format string}`` where format string is

pandas/tseries/frequencies.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ def infer_freq(index, warn=True):
222222
Parameters
223223
----------
224224
index : DatetimeIndex or TimedeltaIndex
225-
if passed a Series will use the values of the series (NOT THE INDEX)
225+
if passed a Series will use the values of the series (NOT THE INDEX).
226226
warn : bool, default True
227227
228228
Returns

0 commit comments

Comments
 (0)