Dark Mode
Image
  • Sunday, 08 December 2024
R Vs Python Programming

R Vs Python Programming

R is a very high-level functional language and is tightly optimized for data science work and statistics. R uses vectorization at the language level, meaning that you treat data as vectors and manipulate it with linear algebra like operations. It can be shockingly easy to do complicated things in R, but surprisingly difficult to do relatively simple things. It is bad for low level programing.

Python is a "do everything" generalist language. It is a hybrid functional and object-oriented language - although as an aside I would argue that the OOP in python is still weak compared to languages like Java or C#. With the right packages (especially numpy or pandas) you can do vectorized operations like you would in R or any statistical language, but you can also (e.g.) build a web application with Django or any number of other things if you want.

Both languages are dynamically typed, easy to set up, and easy to write a quick and dirty script in. Both languages are computationally inefficient when compared to languages that are compiled to assembly, but Python is much more efficient than R. I use both languages and more, but I like learning new programming languages for its own sake, so your milage may differ.

I wouldn't use RStudio for Python personally, but it really depends on how much you want to learn, and what the applications are. If you want to learn more about programming generally, or you want to do machine learning specifically, learn Python first. If you want to do statistics and want to avoid as many programming problems as possible, learn R.

Comment / Reply From

Newsletter

Subscribe to our mailing list to get the new updates!