R, SAS, Shell and PL/SQL Programming: Uses, Setup and How to Run
R programming is used for statistical computing, data analysis, data visualisation and machine learning. Statisticians, data scientists and researchers use it for clinical trials, financial modelling and bioinformatics. Install R free from CRAN and run scripts with RStudio or the command line using Rscript filename.R.
- Key Takeaway 1: R is purpose-built for statistics. It beats Python in bioinformatics, clinical research and advanced visualisation with ggplot2.
- Key Takeaway 2: SAS still dominates pharma and banking in India and globally because of its regulatory acceptance and enterprise support.
- Key Takeaway 3: Shell scripting automates repetitive system tasks on Linux/Ubuntu servers. It is the backbone of DevOps and cloud operations.
- Key Takeaway 4: PL/SQL is Oracle’s procedural extension to SQL. You run PL/SQL blocks inside SQL*Plus or SQL Developer to handle complex database logic.
- Key Takeaway 5: Each language solves a distinct problem. Knowing which tool to reach for, and when, is what separates junior analysts from senior engineers.
What Is R Programming Used For and How to Install and Run It
What is R programming used for, exactly? R was created by Ross Ihaka and Robert Gentleman at the University of Auckland in 1993. Today it is maintained by the R Foundation for Statistical Computing and downloaded from CRAN (the Comprehensive R Archive Network). According to the TIOBE Index (June 2025), R sits consistently in the top 15 programming languages worldwide, with particularly strong adoption in academia and research institutions.
Indian organisations like ICMR, AIIMS, IITs and pharmaceutical companies such as Sun Pharma use R for biostatistics, epidemiological modelling and genomics. According to CRAN download metrics (2024), the ggplot2 package has been downloaded over 100 million times, making it one of the most-used data visualisation libraries in any language. Understanding what R programming is used for starts with recognising that its statistical depth is unmatched among general-purpose languages.
Explore structured courses covering R, data science and AI at the 3.0 University online certification courses page.
Where R Beats Python and Where It Does Not
R programming is used for rigorous statistical testing, mixed-effects models, survival analysis and publication-ready plots. Clinical trials in India that submit data to regulators like CDSCO often use R because of packages like survival, lme4 and Hmisc. R’s statistical depth is broader than Python’s base libraries, which is why researchers asking what R programming is used for almost always land on clinical and academic work first.
Python wins in production deployment, web scraping, deep learning pipelines and general software engineering. If you are building an ML model that ships into a web app, Python with FastAPI or Flask is the more practical choice. Many data teams use both: R for analysis and reporting, Python for engineering and deployment.
How to Install R Programming on Windows, macOS and Linux
- Go to cran.r-project.org and download the installer for your operating system (Windows, macOS or Linux).
- Run the installer and accept the defaults. R installs in under two minutes on most machines.
- Download RStudio Desktop from posit.co. RStudio is a free IDE that makes working with R dramatically easier.
- Open RStudio. You will see a console, script editor and environment panel. Type 2 + 2 in the console and press Enter to confirm it is working.
- Install your first package: type install.packages(“ggplot2”) in the console and press Enter.
How to Run an R Script from the Command Line
Inside RStudio, write your code in the script editor, save the file as analysis.R and click Run. For automation or server jobs, use the command line instead.
Open your terminal and type:
Rscript analysis.R
Rscript runs the file top to bottom without opening any GUI. This is how R scripts run on cloud servers, in cron jobs and inside CI/CD pipelines. If you are working with data science workflows and want to understand how R programming used for analytics connects to broader AI careers, the career shift from data science to AI/ML is a natural progression worth exploring.
| Language | Primary Use | Top Package/Tool | India Job Demand (Naukri.com, Dec 2024) |
|---|---|---|---|
| R | Statistical analysis, research | ggplot2, dplyr, caret | ~18,000 active listings |
| SAS | Pharma, banking, clinical trials | SAS Base, SAS/STAT | ~22,000 active listings |
| Shell/Bash | System automation, DevOps | Bash, Zsh, AWK | ~35,000 active listings |
| PL/SQL | Oracle database programming | SQL*Plus, SQL Developer | ~28,000 active listings |
Source: Naukri.com job listings data, December 2024.
SAS and Where It Still Dominates
SAS (Statistical Analysis System) was developed by SAS Institute starting in 1966 at North Carolina State University. It is a licensed software suite, not open-source, and that is part of why it still commands premium salaries. Regulatory bodies like the US FDA formally accept SAS output for drug approval submissions, which makes it non-negotiable in clinical research.
In India, SAS professionals are heavily recruited by companies like Cognizant, TCS, Wipro and Sun Pharma for roles in clinical data management, risk analytics and fraud detection. According to the AmbitionBox Salary Report (2023), SAS programmers in India earn between Rs 6 LPA and Rs 18 LPA depending on experience and domain.
What SAS Does That R Struggles With at Enterprise Scale
SAS handles massive datasets with built-in data management procedures. Its PROC SQL, PROC MEANS and PROC REPORT steps are battle-tested in environments where auditability and reproducibility are legal requirements, not just best practices. SAS also has dedicated technical support, which enterprise clients pay for and rely on.
The honest downside: SAS licences are expensive, the community is smaller than R or Python, and it is less flexible for modern ML workflows. If you are a student choosing between SAS and R, learn R first for the fundamentals. Add SAS if you are targeting pharma or banking specifically.
If you want to see how analytics skills like SAS and R fit into the broader picture of high-growth technology careers, this breakdown of AI, blockchain and data science careers in India gives useful context.
Shell and PL/SQL Scripting Basics
What Is Shell Programming?
Shell programming means writing scripts that the operating system’s shell interpreter executes. On Linux and macOS, that is usually Bash (Bourne Again Shell). On Windows, it is PowerShell. Shell scripts automate tasks: moving files, scheduling backups, deploying code, monitoring servers and chaining together other programs.
Every DevOps engineer, cloud architect and system administrator writes shell scripts. According to the Stack Overflow Developer Survey 2024, Bash/Shell is used by over 32% of professional developers, making it one of the most-used scripting environments in the world.
How to Run a Shell Program in Ubuntu
- Create a new file: nano hello.sh
- Type your script. Start with the shebang line: #!/bin/bash on line one, then add echo “Hello from 3.0 University” on line two.
- Save and exit nano (Ctrl+O, Enter, Ctrl+X).
- Make the script executable: chmod +x hello.sh
- Run it: ./hello.sh
The chmod +x step is what most beginners miss. Without it, Ubuntu will not execute the file because it lacks execution permission. Once you have that down, you can build scripts that loop through directories, process log files or trigger API calls automatically.
How to Execute a PL/SQL Program in Oracle Database
PL/SQL is Oracle Database’s procedural language. It extends standard SQL with variables, loops, conditionals and exception handling. You use it to write stored procedures, triggers and functions that run inside the database engine itself, which is far more efficient than sending hundreds of individual SQL queries from an application.
Here is how to run a basic anonymous PL/SQL block in SQL*Plus:
- Connect to your Oracle database: type sqlplus username/password@database in your terminal.
- At the SQL prompt, type your block. Start with BEGIN, add your logic (for example, DBMS_OUTPUT.PUT_LINE(‘Hello World’);), then close with END;
- Type a forward slash / on a new line and press Enter to execute.
- Enable output first with SET SERVEROUTPUT ON if you want to see DBMS_OUTPUT results.
In Oracle SQL Developer (the GUI tool), paste the same block into the worksheet, highlight it and press the Run Script button (F5). SQL Developer is easier for beginners because it shows output and errors in a separate panel without needing to configure SERVEROUTPUT manually.
PL/SQL skills are in high demand across Indian banking, insurance and ERP sectors where Oracle Database underpins core systems. Understanding how algorithmic logic works inside databases ties directly into the broader AI algorithm essentials that power modern data-driven applications.
If you are building skills across multiple tools and want to track them with recognised credentials, check out the GitHub Education program for developers for free developer tools that support your learning environment.
The 3.0 University learning hub covers all of these topics in structured, industry-aligned courses. Whether you are a student, a working professional adding new skills or someone switching careers entirely, structured learning cuts months off the trial-and-error phase.
Frequently Asked Questions
What is R programming used for?
R programming is used for statistical analysis, data visualisation, machine learning and research. It is particularly strong in clinical trials, bioinformatics, academic research and financial modelling. The ggplot2 package makes it a favourite for publication-quality charts. Indian institutions like IITs, AIIMS and ICMR use R extensively for data-driven research projects.
How do I install and run R programming?
Download R from cran.r-project.org and install RStudio from posit.co for a full IDE experience. To run a script from the command line, use Rscript yourfile.R. That works on Windows, macOS and Linux without opening any graphical interface, making it ideal for server-side and automated workflows.
What is SAS programming used for?
SAS is used for enterprise statistical analysis, clinical data management, risk analytics and fraud detection. It is the standard in pharmaceutical companies submitting data to the FDA and other regulators. In India, SAS roles are common in companies like TCS, Cognizant and major pharma firms, with salaries ranging from Rs 6 LPA to Rs 18 LPA according to AmbitionBox (2023).
What is shell programming and how do I run a shell program in Ubuntu?
Shell programming means writing Bash scripts to automate operating system tasks. On Ubuntu, create a file ending in .sh, add #!/bin/bash at the top, write your commands, then run chmod +x filename.sh to make it executable. Execute it with ./filename.sh. It is the foundation of Linux administration and DevOps automation.
How do I run a PL/SQL program in Oracle?
Connect to Oracle Database via SQL*Plus or SQL Developer. Write an anonymous block starting with BEGIN and ending with END;, then execute it with a forward slash in SQL*Plus or F5 in SQL Developer. Always run SET SERVEROUTPUT ON first if you are using DBMS_OUTPUT to print results to the screen.
Is R programming still relevant in 2025?
Yes. R programming is used for statistical computing across pharma, academia and finance globally. According to the TIOBE Index (June 2025), R remains in the top 15 programming languages. In India, Naukri.com listed approximately 18,000 active R-related job postings in December 2024, confirming strong ongoing demand.
Ready to move from reading about these tools to actually using them in real projects? Explore 3.0 University’s online certification courses in Cybersecurity, Ethical Hacking, AI, Blockchain and Web3. The programmes are built for students, working professionals and career switchers who want practical, industry-ready skills they can apply from day one.
Last updated: June 2025. Reviewed by the 3University editorial team.


