[Pandas-dev] Consensus on pct_change

Marc Garcia garcia.marc at gmail.com
Thu Jul 11 06:58:38 EDT 2019


I'm -1 on changing the method, but I think the docstring of pct_change can
be improved, and also include a note for that.

Can you (or may be your students) open an issue or PR for this? Since you
found it confusing, I think you're the best people to clarify the
documentation and write it in a way that other people don't have the same
misunderstanding as you just had.

Thanks!

On Wed, Jul 10, 2019 at 4:08 PM Matthew Brett <matthew.brett at gmail.com>
wrote:

> Hi,
>
> On Wed, Jul 10, 2019 at 7:59 AM Chris Bartak <cbartak at gmail.com> wrote:
> >
> > I'm sure it depends on your background (mine is more financial than
> academic), but at least for some users this isn't confusing or surprising -
> I would say 10% is equivalent to 0.10.  Excel works that way, as well as
> most pocket calculators with a '%' key.
>
> I think we agree that 0.1 is a proportion and 10 is a percentage, and
> it's easy to display a proportion as a percentage (by multiplying by
> 100).  So, if there was some way of keeping track of the values as
> being a proportion, and displaying as a percentage, this would make
> sense.   So, the ideal might be a function called prop_change that
> returned the current values, but displayed as a percentage.
>
> I think you're right though - there isn't an easy way of doing that -
> hence the confusion.
>
> Cheers,
>
> Matthew
> _______________________________________________
> Pandas-dev mailing list
> Pandas-dev at python.org
> https://mail.python.org/mailman/listinfo/pandas-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/pandas-dev/attachments/20190711/e4b47aad/attachment.html>


More information about the Pandas-dev mailing list