Is R is more speedy than Python on tranformation and grouping of same size of dataframes

Python_analysis.pdf (205.6 KB)
R_analysis.pdf (228.4 KB)
i am comming from python background
I just started to learn R and find it more inatuitive than python.
I pasted similar scripts in both python and R on a linux run jupyter notebook which create same size dataframe and then do the same transformation and summarization.
i run the scripts and found that R run faster than python. details attached in pdf
Please guide

I don't know the answer - and will be interested to see the replies.

I did find this article comparing sort (not group_by) Data Wrangling/ETL Tools Comparison : R, Pandas,Knime,Power Query,Tableau Prep,Alteryx
I think we should ignore their native R implementation. But they have pandas faster than dplyr - but slower than data.table

data.table is worth a mention if speed is everything to you. It allows multi-threading. I don't know how well that applies to grouping.

I also find R/dplyr more intuitive than python. But if google R vs python there are a lot of articles talking about R being learner-unfriendly, only for statistics and even low-level. I have yet to read a well-researched article with a well-reasoned comparison.

1 Like

These benchmarks are a bit old, but show the differences on large datasets:
Database-like ops benchmark (h2oai.github.io)

1 Like

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.