-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
add densityplot #2741
add densityplot #2741
Conversation
I think it adds something. Not sure about the name though
…On 3 Dec 2017 14:50, "Osvaldo Martin" ***@***.***> wrote:
In the same *spirit* of #2736
<#2736> a densityplot can be used
to compare several traces/models (and also works for a single trace/model).
[image: index]
<https://user-images.githubusercontent.com/1338958/33525822-b2fff0f8-d815-11e7-8c19-ead4e3800ee0.png>
The KDE plots are truncated at their HPD interval, a point estimate (the
mean by default) is represented using... a point. Each group of variables
share the same scale (like in a traceplot and unlike a forestplot). At some
point I though about implementing a ridgeline plot (AKA joyplot) but I am
still not connived that those plots add too much value except for their
coolness and fanciness.
Let me know if you think this could be a good addition to the PyMC3 plots,
suggestions for alternative names are also welcomed.
------------------------------
You can view, comment on, or merge this pull request online at:
#2741
Commit Summary
- add densityplot
File Changes
- *M* docs/source/api/plots.rst
<https://github.com/pymc-devs/pymc3/pull/2741/files#diff-0> (2)
- *M* docs/source/notebooks/model_averaging.ipynb
<https://github.com/pymc-devs/pymc3/pull/2741/files#diff-1> (184)
- *M* pymc3/plots/__init__.py
<https://github.com/pymc-devs/pymc3/pull/2741/files#diff-2> (1)
- *A* pymc3/plots/densityplot.py
<https://github.com/pymc-devs/pymc3/pull/2741/files#diff-3> (155)
Patch Links:
- https://github.com/pymc-devs/pymc3/pull/2741.patch
- https://github.com/pymc-devs/pymc3/pull/2741.diff
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#2741>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AA8DiMvEebRpW4Xu0IU8J2Qg-XUnPZB9ks5s8qdBgaJpZM4Qzucb>
.
|
Thanks for the feedback @springcoil, just to add perspective the previous name was |
Maybe Density plot is fine. Compared to aplot. I'd add that to the release
notes
…On 3 Dec 2017 15:06, "Osvaldo Martin" ***@***.***> wrote:
Thanks for the feedback @springcoil <https://github.com/springcoil>, just
to add perspective the previous name was aplot :-)
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2741 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AA8DiMhtI_pKXWkBfdUxwgFclrc0lujLks5s8qr1gaJpZM4Qzucb>
.
|
Thanks for including the sample! Can you show a snippet of code that would produce that? I am wondering in particular what |
Hi @ColCarroll You will have to do: This PR also adds a very simple usage example to an existing notebook of the |
I like this last one. Do you think it's worth merging now, and iterating on it in the future. |
Hi @springcoil, I need to commit the code for the last two figures and I should add a test. I could do it tomorrow. I guess we don't need to choose between these 3 variations, they can be offered as different options, but which one should be the default one? The last one? @ColCarroll what do you think? |
Yeah a test would help. I think having three options is good, I think the last one should be the default one. |
@springcoil thanks for the feedback! I will work on this. |
Probably helpful to mimic the api of https://seaborn.pydata.org/examples/distplot_options.html , since it will be known to users already. In particular, they pass in Also agree that we can iterate on some of this after merging, so it isn't all on you! |
Yeah I think shipping this, and then people experimenting with it will mean that the load isn't all on you. |
Following your suggestions, @springcoil and @ColCarroll, I update the code and set a different default style. I changed the name of argument |
LGTM :) |
* add densityplot * add new default style and new options, add test and update release notes and example
In the same spirit of #2736 a
densityplot
can be used to compare several traces/models (and also works for a single trace/model).The KDE plots are truncated at their HPD interval, a point estimate (the mean by default) is represented using... a point. Each group of variables share the same scale (like in a traceplot and unlike a forestplot). At some point I though about implementing a ridgeline plot (AKA joyplot) but I am still not connived that those plots add too much value except for their coolness and fanciness.
Let me know if you think this could be a good addition to the PyMC3 plots, suggestions for alternative names are also welcomed.