Op 16 maart 2012 12:34 heeft Conrad Lee <[email protected]> het volgende geschreven: > If so, then a couple more questions remain. Does scikit-learn support > structured arrays, or do those need to be converted to 2-d arrays? Is it > important for some of the models that the booleans be represented a as > floats rather than as booleans? If so, then the default type for > `bool_dtype` in the snippet should be a floating point type.
Practically all of the estimators will try to convert whatever they get to 2-d arrays with np.asarray or np.atleast_2d. Some will want dtype=np.float64, others work with what they get. > We could try to create a function that takes an arbitrary matrix of feature > vectors, and automatically converts the fields that appear to be categorical > into boolean fields. Of course, we won't be able to write a function that > always knows which fields are categorical and which are numeric, but we > could have default values that get it right most of the time. How do you propose to do that? -- Lars Buitinck Scientific programmer, ILPS University of Amsterdam ------------------------------------------------------------------------------ This SF email is sponsosred by: Try Windows Azure free for 90 days Click Here http://p.sf.net/sfu/sfd2d-msazure _______________________________________________ Scikit-learn-general mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
