Re: [Scikit-learn-general] Sparse feature matrix generation

2012-01-14 Thread Lars Buitinck
2012/1/6 Dhruvkaran Mehta : > Is there a convenient way in scikits to go from "string" features like: ... > to a numpy matrix like: ... At present, no. But I donated a scikit-learn wrapper to NLTK yesterday, which translates NLTK's featuresets (dicts mapping feature names to numeric or boolean

[Scikit-learn-general] Sparse feature matrix generation

2012-01-14 Thread Dhruvkaran Mehta
Hi scikit-learn users, *Is there a convenient way in scikits to go from "string" features like:* "uc_berkeley", "google", 1 "stanford", "intel", 1 . . . "uiuc", "texas_instruments", 0 *to a numpy matrix like:* "uc_berkeley", "stanford", ..., "uiuc", "google", "intel", "texas_instruments", "boo