Re: [Python-ideas] Users of statistics software, what quantile functionality would be useful for you?

2019-04-27 Thread Stephan Hoyer
On Sat, Apr 27, 2019 at 6:10 AM Steven D'Aprano wrote: > The statistics module is soon to get a quantile function. > > For those of you who use statistics software (whether in Python, or > using other languages) and specifically use quantiles, what sort of > functionality would be useful to you?

Re: [Python-ideas] Syntax to conditionally define a field in a dict

2019-04-27 Thread Joao S. O. Bueno
Calling upon ol' Guidos Time Machinne: In [31]: def create(val1): ...: data = { ...: **({"val1": "me here"} if val1 else {}) ...: } ...: return data ...: In [32]: create(False) Out[32]: {} In [33]: create(True) Out[33]: {'val1': 'me here'} Now, please, just mo

Re: [Python-ideas] Syntax to conditionally define a field in a dict

2019-04-27 Thread Christopher Barker
yes, this can already be done, and yes, mapping unpacking is little used (I never think to use it). But in this case, it's a no-op, not sure the point. I get the same thing with just the ternary expression: In [11]: def create(val1): ...: data = {"val1": "me here"} if val1 else {} ...:

[Python-ideas] Users of statistics software, what quantile functionality would be useful for you?

2019-04-27 Thread Steven D'Aprano
The statistics module is soon to get a quantile function. For those of you who use statistics software (whether in Python, or using other languages) and specifically use quantiles, what sort of functionality would be useful to you? For example: - evenly-spaced quantiles (say, at 0.25, 0.5, 0.7