From 1fd46114b5aa81e84910098815dade7d05bc49fe Mon Sep 17 00:00:00 2001 From: mram Date: Tue, 16 Apr 2019 20:30:40 -0400 Subject: [PATCH 1/3] Updated PeriodIndex docstrings --- pandas/core/arrays/period.py | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/pandas/core/arrays/period.py b/pandas/core/arrays/period.py index 70312f2e61445..25b10d1d54373 100644 --- a/pandas/core/arrays/period.py +++ b/pandas/core/arrays/period.py @@ -439,19 +439,13 @@ def asfreq(self, freq=None, how='E'): -------- >>> pidx = pd.period_range('2010-01-01', '2015-01-01', freq='A') >>> pidx - - [2010, ..., 2015] - Length: 6, Freq: A-DEC + PeriodIndex(['2010', '2011', '2012', '2013', '2014', '2015'], dtype='period[A-DEC]', freq='A-DEC') >>> pidx.asfreq('M') - - [2010-12, ..., 2015-12] - Length: 6, Freq: M + PeriodIndex(['2010-12', '2011-12', '2012-12', '2013-12', '2014-12', '2015-12'], dtype='period[M]', freq='M') >>> pidx.asfreq('M', how='S') - - [2010-01, ..., 2015-01] - Length: 6, Freq: M + PeriodIndex(['2010-01', '2011-01', '2012-01', '2013-01', '2014-01', '2015-01'], dtype='period[M]', freq='M') """ how = libperiod._validate_end_alias(how) From 11aea32e6fd991e05903e3d772ec9c7665eb0f62 Mon Sep 17 00:00:00 2001 From: mram Date: Tue, 16 Apr 2019 20:42:42 -0400 Subject: [PATCH 2/3] Linesize --- Pipfile | 11 +++++++++++ pandas/core/arrays/period.py | 9 ++++++--- 2 files changed, 17 insertions(+), 3 deletions(-) create mode 100644 Pipfile diff --git a/Pipfile b/Pipfile new file mode 100644 index 0000000000000..b9ba84f6772f7 --- /dev/null +++ b/Pipfile @@ -0,0 +1,11 @@ +[[source]] +url = "https://pypi.org/simple" +verify_ssl = true +name = "pypi" + +[packages] + +[dev-packages] + +[requires] +python_version = "3.7" diff --git a/pandas/core/arrays/period.py b/pandas/core/arrays/period.py index 25b10d1d54373..b0b87d98ce518 100644 --- a/pandas/core/arrays/period.py +++ b/pandas/core/arrays/period.py @@ -439,13 +439,16 @@ def asfreq(self, freq=None, how='E'): -------- >>> pidx = pd.period_range('2010-01-01', '2015-01-01', freq='A') >>> pidx - PeriodIndex(['2010', '2011', '2012', '2013', '2014', '2015'], dtype='period[A-DEC]', freq='A-DEC') + PeriodIndex(['2010', '2011', '2012', '2013', '2014', '2015'], + dtype='period[A-DEC]', freq='A-DEC') >>> pidx.asfreq('M') - PeriodIndex(['2010-12', '2011-12', '2012-12', '2013-12', '2014-12', '2015-12'], dtype='period[M]', freq='M') + PeriodIndex(['2010-12', '2011-12', '2012-12', '2013-12', '2014-12', + '2015-12'], dtype='period[M]', freq='M') >>> pidx.asfreq('M', how='S') - PeriodIndex(['2010-01', '2011-01', '2012-01', '2013-01', '2014-01', '2015-01'], dtype='period[M]', freq='M') + PeriodIndex(['2010-01', '2011-01', '2012-01', '2013-01', '2014-01', + '2015-01'], dtype='period[M]', freq='M') """ how = libperiod._validate_end_alias(how) From f562dcd97d9d814ad8d704aa26f32b1c2c04e120 Mon Sep 17 00:00:00 2001 From: Mukul Ashwath Ram Date: Tue, 16 Apr 2019 20:51:58 -0400 Subject: [PATCH 3/3] Removed file that was accidentally committed. --- Pipfile | 11 ----------- 1 file changed, 11 deletions(-) delete mode 100644 Pipfile diff --git a/Pipfile b/Pipfile deleted file mode 100644 index b9ba84f6772f7..0000000000000 --- a/Pipfile +++ /dev/null @@ -1,11 +0,0 @@ -[[source]] -url = "https://pypi.org/simple" -verify_ssl = true -name = "pypi" - -[packages] - -[dev-packages] - -[requires] -python_version = "3.7"