2013/6/17 Lars Buitinck <[email protected]>:
> 2013/6/17 Andreas Mueller <[email protected]>:
>> On 06/17/2013 04:46 PM, Gael Varoquaux wrote:
>>>> With a long enough deprecation cycle, I'm +1.
>>> I am -1 because I like the flexibility of the bunch-like object. However,
>>> I think that we could move to a dictionary.
>>>
>> We could also use a named tuple.
>> That would also support unwrapping, so we could have flexibility but
>> could also directly access the content.
>
> Named what, Bunch? :p

The Bunch class does not allow the following oneliner:

X, y = load_iris()[:2]

while a namedtuple would as the attributes are ordered in a namedtuple.

That being said, if Bunch were to derive from
http://docs.python.org/2/library/collections.html#collections.OrderedDict
we could make it work. But that would require us to backport
OrderedDict in sklearn/utils/fixes.py to keep python 2.6 compat.

--
Olivier
http://twitter.com/ogrisel - http://github.com/ogrisel

------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Scikit-learn-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/scikit-learn-general

Reply via email to