To filter a #Python #Pandas data frame by rows, use the same syntax and rules as for series: df.loc[ lambda df_: df_['x'] > df_['w'] ] The lambda still returns a boolean series. The expression can use any column from the data frame. Tomorrow: How Pandas 3 improves on this.
2 likes 0 replies
?