Hacker News new | past | comments | ask | show | jobs | submit login

> Second, there are callbacks! The second argument in DataFrame.filter/2 takes a callback function against the dataframe. There’s some cool stuff we can do with that, and I think callbacks against the dataframe are a natural way to work.

I'm not enamoured with how DataFrame.filter/2 reads compared to the dplyr example. I've written very little R but read code by others and find dpylr excellent for that; and I use a JS 'port' of dplyr [1] for projects. I'm in the "hate pandas" camp and find it painful to both read and write - and these callback functions are coming too close to Pandas for my liking. I hope an alternative can be found

1. https://pbeshai.github.io/tidy/




For further inspiration, this is a pretty good-looking "dplyr for Python": https://github.com/machow/siuba

There's precedent in Ecto for a "magic" operator (`^` if I'm not mistaken), so it wouldn't be a stretch to implement it here as well.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: