You probably want https://github.com/paulgb/sklearn-pandas this is will
convert pandas dataframes into something sklearn likes.


On Sat, Nov 16, 2013 at 5:11 PM, Josh Wasserstein <[email protected]>wrote:

> Say I have a dataframe in Pandas like the following:
>
> > my_dataframe
> col1, col2
> A      foo
> B      bar
> C      something
> A      foo
>  A      bar
> B      foo
>
> How can I vectorize this efficiently using DictVectorizer ?
>
> Do I need to convert each entry above to a full dictionary? Is there a
> more efficient way to do this?
>
> Thanks,
>
> Josh
>
>
> ------------------------------------------------------------------------------
> DreamFactory - Open Source REST & JSON Services for HTML5 & Native Apps
> OAuth, Users, Roles, SQL, NoSQL, BLOB Storage and External API Access
> Free app hosting. Or install the open source package on any LAMP server.
> Sign up and see examples for AngularJS, jQuery, Sencha Touch and Native!
> http://pubads.g.doubleclick.net/gampad/clk?id=63469471&iu=/4140/ostg.clktrk
> _______________________________________________
> Scikit-learn-general mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
>
>
------------------------------------------------------------------------------
DreamFactory - Open Source REST & JSON Services for HTML5 & Native Apps
OAuth, Users, Roles, SQL, NoSQL, BLOB Storage and External API Access
Free app hosting. Or install the open source package on any LAMP server.
Sign up and see examples for AngularJS, jQuery, Sencha Touch and Native!
http://pubads.g.doubleclick.net/gampad/clk?id=63469471&iu=/4140/ostg.clktrk
_______________________________________________
Scikit-learn-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/scikit-learn-general

Reply via email to