arviz-devs / arviz

Exploratory analysis of Bayesian models with Python
https://python.arviz.org
Apache License 2.0
1.59k stars 395 forks source link

KDE backend function documentation missing #2189

Open zachjweiner opened 1 year ago

zachjweiner commented 1 year ago

The docstring of kde cites kde_linear and kde_circular for details on keyword args, but their docstrings don't appear in the documentation. (Note that both methods actually have leading underscores.)

zachjweiner commented 1 year ago

To make matters worse, the KDE backend functions take arbitrary kwargs (even though none use them) without complaint, so it's basically impossible to know what one can and can't do without locating and then importing the backend method from arviz.stats.density_utils to query its docstring (and also realizing the function name is actually prefixed with an underscore, in contrast to the arviz.kde docstring).

I'm happy to implement a solution if it'd be helpful, if a maintainer can make a decision (whether to change the backend function names or just fix the docstring, on what page to add the backend methods' documentation, etc.).

OriolAbril commented 1 year ago

These should not be private methods but public ones. It would be great if you can make these changes. From the top of my hand you'll need to:

zachjweiner commented 1 year ago

Thanks - I'll try to get to this soon.

Maybe it'd be prudent to try and tackle #2190 at the same time? Let me know what you think.

OriolAbril commented 1 year ago

I'd probably do 2 different PRs, one per issue, but either way should be fine