When it comes to popularity, its fair to say python is eating the world. Created by Guido van Rossum frustrations in the shortcomings of other languages. It has a generic, English readability appeal to it and a very large community of active users are just a few of the attractions here. According to the IEEE (the world’s largest technical org), Python continues to maintain its number one status as the most popular syntax for programmers. It acts as a self-fulfilling prophesy as more and more people gravitate towards it, it continues to maintain its grip at number one.
In terms of libraries, these are both open source languages, both with large communities so they do well generally speaking in this area. However, more likely to find out of date packages when it comes to utilizing R as its not used as frequently for production code by companies.
R is predominantly used by PhD researchers as their performing vast amounts of a statistical analysis on data. Python has that English readability factor to it, general consensus therefore is R is harder to learn though learning either allow you to cross-over more easily to the other.
If we were talking research led jobs we might finish off on equal footings but even then, most actual jobs will at most run the statistical data work in R and ask for implementation and deployment in Python as thats one of its key strength – high performance. generally, speaking a greater number of opportunities exist that ask for Python which ties back into the self-fulfilling prophecy of it consequently delving its continued popularity.
In the end, if your goal is to do intense statistical analysis you may be swayed to wards R otherwise for deploying models that work in real-life production scenarios, Python all the way!