Skip to content
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

DOC: improve documentation for Series.resample #5023

Closed
2 of 8 tasks
cancan101 opened this issue Sep 28, 2013 · 9 comments
Closed
2 of 8 tasks

DOC: improve documentation for Series.resample #5023

cancan101 opened this issue Sep 28, 2013 · 9 comments
Labels
Datetime Datetime data dtype Docs good first issue Period Period data type

Comments

@cancan101
Copy link
Contributor

cancan101 commented Sep 28, 2013

Reference docs (see: http://pandas.pydata.org/pandas-docs/stable/generated/pandas.Series.resample.html):

Tutorial docs:

  • example using custom how function
  • example showing how to use base
@jreback
Copy link
Contributor

jreback commented Sep 28, 2013

@cancan101 this one

@jorisvandenbossche
Copy link
Member

some more issues:

  1. how can also be a function or list of functions, not only a string
  2. for the closed and label keywords, I think it could be explained which are default in which cases (which is not always the same). In every case, that label='right' is default as stated in the docs (http://pandas.pydata.org/pandas-docs/dev/timeseries.html#up-and-downsampling) is not true.

@Winterflower
Copy link
Contributor

Working on adding examples into the resample API docs. Hopefully this will help users who don't have time to read the tutorials to use resample.

@kdebrab
Copy link
Contributor

kdebrab commented Jan 27, 2017

FWIW: By default resample uses start timestamp convention (i.e. closed='left' and label='left'), except for weekly, monthly, quarter and annual resolution, where the default is end timestamp convention (i.e. closed='right' and label='right', in other words the week, month, quarter or year is represented by its last day). The code doing that is here: https://github.com/pandas-dev/pandas/blob/v0.19.2/pandas/tseries/resample.py#L983-L997.

As of 0.19.2, the incorrect documentation about label='right' is to be found in the comment of code input [245] on http://pandas-docs.github.io/pandas-docs-travis/timeseries.html#basics.

@jreback
Copy link
Contributor

jreback commented Jan 27, 2017

sure a PR would be great for this

@jorisvandenbossche jorisvandenbossche changed the title Improve documentation for Series.resample DOC: improve documentation for Series.resample Feb 17, 2017
@jreback jreback added Difficulty Novice Period Period data type labels Feb 17, 2017
@Peque
Copy link
Contributor

Peque commented Jun 8, 2017

Apparently there is also an undocumented limit parameter (not even mentioned in the docstring).

@jorisvandenbossche
Copy link
Member

An explanation of the limit keyword is indeed missing, but note that this stems from the previous (deprecated) interface, so maybe not worth to add it anymore (as I think we might remove those deprecated things in the next release)

@fding253
Copy link
Contributor

fding253 commented Jul 15, 2017

Working on adding documentation for the convention parameter.

@mroeschke
Copy link
Member

mroeschke commented Mar 31, 2020

Since the resample API has changed since the original issue has been posted. I think most of the original points have been addressed:

  • closed default behavior is specified
  • how is no longer relevant (bfill and ffill are separate methods)

We can open up individual issues for any remaining improvements documentation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Datetime Datetime data dtype Docs good first issue Period Period data type
Projects
None yet
Development

No branches or pull requests

10 participants