From 9c437f5210b1c44d1ecf67c63a6692a23c5b00a9 Mon Sep 17 00:00:00 2001 From: huang06 Date: Sat, 18 Dec 2021 14:36:02 +0800 Subject: [PATCH] DOC: Fix mistake in code example --- doc/source/user_guide/timeseries.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/source/user_guide/timeseries.rst b/doc/source/user_guide/timeseries.rst index fde9ff0450a12..3fd6fe67772bc 100644 --- a/doc/source/user_guide/timeseries.rst +++ b/doc/source/user_guide/timeseries.rst @@ -2424,7 +2424,7 @@ you can use the ``tz_convert`` method. For ``pytz`` time zones, it is incorrect to pass a time zone object directly into the ``datetime.datetime`` constructor - (e.g., ``datetime.datetime(2011, 1, 1, tz=pytz.timezone('US/Eastern'))``. + (e.g., ``datetime.datetime(2011, 1, 1, tzinfo=pytz.timezone('US/Eastern'))``. Instead, the datetime needs to be localized using the ``localize`` method on the ``pytz`` time zone object.