I will try to give me own humble opinion as a doctor and an academic who uses SAS, R and Python.
I agree with KurtBremser, you should learn both… and not only that, you should also learn python in addition these two.
SAS has a number of major advantages over other languages/ environments:
Its speed and ability to handle large databases is miles ahead of R. Proc SQL is an absolute beast in this area (yes you can run SQL code in R but there is no comparison to the way SAS implements it).
All procedures in SAS are thoroughly and comprehensively tested and validated before being released. You know you can trust the output from any SAS procedure to be correct, period! (that is if you code it correctly of course). Most R libraries (apart from base R) are written by individuals and that makes them less reliable (see below)
SAS just works out of the box once installed, you do not need to instal and load libraries as in R or packages for Python that not infrequently fail to load (especially in enterprise setting with security protocols that might interfere with installation of external packages)
Importantly, the support you get from forums (and I mean SAS communities) is just incredible, you cannot get this level of friendly and quick support for R (you have to turn to stackoverflow, and my experience it is not as good as SAS communities…by light years)
SAS is just good, efficient, reliable and there is massive enterprise supporting it. It is here to stay and it is not used by large enterprises for no reason.
SAS has drawbacks….
It is a commercial software, meaning it is expensive, and every module you add costs a fortune… you spend hundreds of dollars for an annual licence and then you only get base SAS
SAS lacks support for machine learning, you need to (guessed it, spend more money) to get a seperate license for SAS Viya… a different module to run AI analytics, this is a HUGE disadvantage, I think.
It is sometimes cumbersome to do some tacks in SAS, graphics editing sucks in SAS and you might need a long code in proc template to make a minor adjustment in a graph
Code sharing (GitHub integration) between users is not as easy as in R
R is incredibly diverse when it comes to the different statistical analyses you can do with it. There is library for basically everything you can think of… This means it is easier and (with shorter code) to solve a specific problem in R, and while this is a strength, it is also R's major weakness. It sometimes becomes confusing to see that the same problem can be solved in many different ways using different libraries that sometimes give you marginally different answers. Furthermore, these libraries are maintained by individuals, and if that person decides for some reason not to maintain the library in question, then it might not work with an R update etc….and while there is good documentation for all R libraries, there is no comparison to the extensive SAS documents supporting each and every procedure in SAS.
Also R is not as memory efficient as SAS, this is especially noticeable when dealing with really big datasets, where R can become incredibly slow..
BUT… R is open source, FREE, versatile, can be installed on Windows or Mac (unlike SAS) supports machine learning and graphics are much easier to manipulate than in SAS… most academics use R nowadays, at my place of work, all researchers use R, and none uses SAS, and working on a project with others is impossible without a reasonable basic knowledge of R.
Some people might find R syntax difficult to get used to… but it gets nicer as you become more comfortable with the code. There are also libraries (dplyr) the improve the syntax.
Also more the jobs nowadays require knowledge in R than SAS:
https://blog.revolutionanalytics.com/2017/02/job-trends-for-r-and-python.html
Python is a must today, it is the go to language for machine learning (and certainly not SAS Viya). It is a magnificent environment to work with. The code is very easy to learn, and it is a very powerful environment for manipulating databases. It is also FREE with a lot of resources online, but it falls well behind R and SAS in terms of its statistical abilities. The packages to deal with complex statistical analyses are just not there yet, but it is rapidly growing. I cannot emphasise enough that it is the go to language when it comes to machine learning.
So, I do not see SAS, R and Python as competitors, they are complementary to each other depending on the task at hand. I have on many occasions previously made the decision to try to use only one of these three as the only tool to do my analyses for ALL my projects, but failed spectacularly, as each is sometimes better suited for a specific problem.
Good luck!
... View more