From 9a7cef73e54ba1b77429a0d5a3057bcb6e57e58e Mon Sep 17 00:00:00 2001 From: harupy Date: Sun, 29 Sep 2019 14:43:02 +0900 Subject: [PATCH 1/2] fix parameter description --- pandas/core/tools/datetimes.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pandas/core/tools/datetimes.py b/pandas/core/tools/datetimes.py index 32dc3c1f3e8f2..af569721e9d39 100644 --- a/pandas/core/tools/datetimes.py +++ b/pandas/core/tools/datetimes.py @@ -627,7 +627,7 @@ def to_datetime( - If True, require an exact format match. - If False, allow the format to match anywhere in the target string. - unit : str, default 'ns' + unit : str, default None unit of the arg (D,s,ms,us,ns) denote the unit, which is an integer or float number. This will be based off the origin. Example, with unit='ms' and origin='unix' (the default), this @@ -637,7 +637,7 @@ def to_datetime( datetime strings, and if it can be inferred, switch to a faster method of parsing them. In some cases this can increase the parsing speed by ~5-10x. - origin : scalar, default is 'unix' + origin : scalar, default 'unix' Define the reference date. The numeric values would be parsed as number of units (defined by `unit`) since this reference date. From c36d72e455d4e1f0b64f4bae672a5652e4adfe5d Mon Sep 17 00:00:00 2001 From: harupy Date: Sat, 5 Oct 2019 09:21:34 +0900 Subject: [PATCH 2/2] Revert unit default value --- pandas/core/tools/datetimes.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pandas/core/tools/datetimes.py b/pandas/core/tools/datetimes.py index af569721e9d39..7b136fa29ecea 100644 --- a/pandas/core/tools/datetimes.py +++ b/pandas/core/tools/datetimes.py @@ -627,7 +627,7 @@ def to_datetime( - If True, require an exact format match. - If False, allow the format to match anywhere in the target string. - unit : str, default None + unit : str, default 'ns' unit of the arg (D,s,ms,us,ns) denote the unit, which is an integer or float number. This will be based off the origin. Example, with unit='ms' and origin='unix' (the default), this