What would be the reason to use one vs the other?
Both are the same, you might be confused because of how it was written in the pandas documentation before and now.
But if you read both documentations the definition is the same
Not the same in terms of how they’re called, same in terms of what they eventually do, both 0.23.4 and 1.1.1 had both api.
mergeis a function in the pandas namespace, and it is also available as a
merge(), with the calling
DataFramebeing implicitly considered the left object in the join.
As stated here
When we use
pd.DataFrame.merge it will implicitly considered the left object in the join. So
df1.merge(right=df2) is equivalent to
Thanks, the answers were very informative. Much appreciated! Essentially one function calls the other. @hanqi So awesome you’d written a whole article about a question I thought might go unanswered.