You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
jreback
changed the title
ENH: Create dataframes using every combination of given values, like R's expand.grid()
ENH: Create dataframes using every combination of given values, like R's expand.grid()
Jun 24, 2014
I find R's
expand.grid()
function quite useful for quick creation of example datasets. For example:A simple implementation of this for
pandas
is easy to put together:Do people think this would be a useful addition?
If so, what kind of features should it have beyond the basics? A
dtypes
argument, specifying which column should be the index, etc.?I'm also not sure if
expand_grid
is the most intuitive name, but given that it's duplicatingR functionality, maybe it's best just to leave it as is.
The text was updated successfully, but these errors were encountered: