HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
machow
siuba
Python2019–2022
machow / siuba

siuba

Python library for using dplyr like syntax with pandas and SQL

4Distinct people
16Mentions
0Explicit recommenders
1.2KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

Python library for using dplyr like syntax with pandas and SQL

GitHub

Where it is used

No documented product use has been verified yet.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

No other repository is repeatedly linked in the same discussions.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 3:56:07 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year16 dated mentions

Observed mentions: 2019-10-18 21:41:22 UTC to 2022-11-02 15:42:47 UTC.

02462019-01-01 00:00:00 UTC to 2020-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments20192020-01-01 00:00:00 UTC to 2021-01-01 00:00:00 UTC (exclusive): 6 mentions; 0 submissions, 6 comments20202021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 3 mentions; 1 submissions, 2 comments2022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 6 mentions; 0 submissions, 6 comments2022

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20192019-01-01 00:00:00 UTC2020-01-01 00:00:00 UTC101
20202020-01-01 00:00:00 UTC2021-01-01 00:00:00 UTC606
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC312
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC606

What Hacker News says

16 sources
This is not a new idea. siuba (a dplyr-like Pandas alternative) is one project that does it, and it also has a "pipeline operator": https://github.com/machow/siuba (mtcars >> group_by(_.cyl) >> summarize(avg_hp = _.hp.mean()) ) (Edit: ok, it seems siuba doesn't have the "parameter fixing" thing.) Related: Coconut - a functional superset of Python - https://github.com/evhub/coconut range(10) |> map$(pow$(?, 2)) |> list There were others but I can't remember which now.
In More intuitive partial function application in Python
Hey, thanks for pointing out Self--I definitely need to dig into fastcore more! One motivation for developing siuba is that the grouped agg you show requires users specify only one operation on one column. E.g. 1. Calculate mean of x However, common operations like demeaning a column are multiple operations: 1. Calculate mean of x 2. Subtract result of (1) from x In siuba you can just write mutate(res = _.x -_.x.mean()). This isn't possible from something like gdf.x.agg("mean"), and from what I can tell deeply confusing to analysts :/. In vanilla pandas I really like to use the chaining method you laid out, and siuba to me is mostly a utility library for making the approach a little more succinct / performant[1]. siuba has experimental autocompletion (thanks to Tim Mastny!), and there's a pretty hefty technical write up on how it uses IPy
Read the rest
thon machinery for that in siuba's architectural desicion record folder[2]. [1]: https://siuba.readthedocs.io/en/latest/developer/pandas-grou... [2]: https://github.com/machow/siuba/blob/master/examples/archite...
In Siuba – A Dplyr Port to Python
Working on siuba, a data analysis tool for python. It's a port of the R library dplyr, and can produces SQL queries! I've programmed in python for much longer than R, and really want to be able to move at the same speed when using python for data analysis :o. It's a weird problem though because the two languages have basically opposite approaches to DataFrames. pandas has a very fat DataFrame implementation, R an extremely minimal one. (Pros and cons to both approaches). https://github.com/machow/siuba
In Ask HN: What weird or hard problems are you trying to solve?
Articles like these are interesting, but what surprises me is that they rarely set up a holistic use case, so most debates imagine how long it would take an expert user to use each tool. But time constraints (eg spent coding) separates expert from novice performance in many domains. FWIW I have 2020 set aside to implement siuba, a python port of the popular R library dplyr (siuba runs on top of pandas, but also can generate SQL). A huge source of inspiration has been screencasts by Dave Robinson using R to analyze data he's never seen before lightning fast. Has anyone seen similar screencasts with pandas? I suspect it's not possible (given some constraints on its interface), but would love to be wrong here, because I'd like to keep all my work in python :o. Expert R screencasts: https://youtu.be/NY0-IFet5AM Siuba: https://github.com/macho
Read the rest
In Scaling Pandas: Comparing Dask, Ray, Modin, Vaex, and Rapids
I've had to dive into the pandas code over the last year for a project [0], and my attitude has shifted dramatically from... * old attitude: why does pandas have to make things so hard * new attitude: pandas has a crazy difficult job I think this is most apparent in the functions that decide what "[d]type" a Block--the most basic thing that stores data in pandas--should be. https://github.com/pandas-dev/pandas/blob/4edcc5541ff3f6470f... And then, for the ubiquitous Object dtype, often figure out which of the many possible more specific types to cast it to. If you think that is easy, ask yourself what this outputs: import numpy as np np.array([np.nan, 'a']) Lo and behold--it produces an array where the np.nan has been converted to the string "nan". And yet import pandas as pd pd.Series([np.nan, "a"]) Knows this, has your b
Read the rest
ack, and does not stringify it. It also has a pathological fixation on when it tries to convert dtypes, since avoiding all the bad conversion outcomes is a relatively time intensive process (compared to e.g. creating a numpy array). I realize things could be much easier in pandas user facing interface, but really appreciate the sheer amount of effort that has gone into its dtype wrangling. [0]: http://github.com/machow/siuba
In Pandas 1.0

Showing the 15 most recent of 16 sources. Enable JavaScript to search and browse every indexed mention.

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.