R Programming - a Comprehensive Guide: Software
By Editor IJSMI
()
About this ebook
R programming has gained importance in different fields due its flexibility, rich packages, platform independent characteristics, data analysis & data visualization capabilities and building various models like machine learning models. It facilitates the incorporation of codes of other languages such as C, C++ and Java in its programming environment.
R programming is an open source platform which is developed by Ross Ihaka and Robert Gentleman from University of Auckland during the year 1991. It is a modified version of S language developed during 1976 by Bell Laboratories in USA. Currently the development process is being handled by the R core development team.
The book starts with the basic concepts such as vectors, objects, factors, data frames, lists, reading data and writing data files, conditions, controls, functions and handling database connections.
Book covers the R Programming rich graphical and data visualization tools, and web applications.
Statistical concepts such as Descriptive, Inferential, and regression models are also covered. It also includes Machine Learning models such as classification and clustering models.
Editor IJSMI,
International Journal of Statistics and Medical Informatics
Editor IJSMI
Editor, International Journal of Statistics and Medical Informatics www.ijsmi.com/book.php editorijsmi@gmail.com
Read more from Editor Ijsmi
Clinical Trial Management – an Overview Rating: 0 out of 5 stars0 ratingsIntroduction To Non Parametric Methods Through R Software Rating: 0 out of 5 stars0 ratingsBayesian Methodology: an Overview With The Help Of R Software Rating: 0 out of 5 stars0 ratingsForecasting Models – an Overview With The Help Of R Software Rating: 0 out of 5 stars0 ratingsDigital Technologies – an Overview of Concepts, Tools and Techniques Associated with it Rating: 0 out of 5 stars0 ratings
Related to R Programming - a Comprehensive Guide
Titles in the series (4)
Mastering Sqribble: Unleashing Your Creativity with Powerful eBook Creation: Software, #1 Rating: 0 out of 5 stars0 ratingsR Programming - a Comprehensive Guide: Software Rating: 0 out of 5 stars0 ratingsOverview Of Bayesian Approach To Statistical Methods: Software Rating: 0 out of 5 stars0 ratingsIntroduction To Business Statistics Through R Software: Software Rating: 0 out of 5 stars0 ratings
Related ebooks
Learning RStudio for R Statistical Computing Rating: 4 out of 5 stars4/5Just Enough R: Learn Data Analysis with R in a Day Rating: 4 out of 5 stars4/5Learn R Programming in 24 Hours Rating: 0 out of 5 stars0 ratingsLearning Jupyter Rating: 5 out of 5 stars5/5Advanced R Statistical Programming and Data Models: Analysis, Machine Learning, and Visualization Rating: 0 out of 5 stars0 ratingsLearn R By Coding Rating: 0 out of 5 stars0 ratingsMastering RStudio – Develop, Communicate, and Collaborate with R Rating: 0 out of 5 stars0 ratingsggplot2 Essentials Rating: 0 out of 5 stars0 ratingsR for Data Science Rating: 5 out of 5 stars5/5R: Data Analysis and Visualization Rating: 5 out of 5 stars5/5Learning R Programming Rating: 5 out of 5 stars5/5R High Performance Programming Rating: 4 out of 5 stars4/5Data Analysis with R Rating: 5 out of 5 stars5/5Handbook of Statistical Analysis and Data Mining Applications Rating: 4 out of 5 stars4/5Statistical Analysis with R For Dummies Rating: 0 out of 5 stars0 ratingsMastering Data Analysis with R Rating: 5 out of 5 stars5/5Python: Real-World Data Science Rating: 0 out of 5 stars0 ratingsLearning Predictive Analytics with R Rating: 0 out of 5 stars0 ratingsData Analytics with Python: Data Analytics in Python Using Pandas Rating: 3 out of 5 stars3/5Machine Learning with R Rating: 4 out of 5 stars4/5Mastering Predictive Analytics with R Rating: 4 out of 5 stars4/5Machine Learning with R - Third Edition: Expert techniques for predictive modeling, 3rd Edition Rating: 0 out of 5 stars0 ratingsMastering Scientific Computing with R Rating: 3 out of 5 stars3/5Big Data Analytics with R Rating: 0 out of 5 stars0 ratingsPractical Data Science with R, Second Edition Rating: 4 out of 5 stars4/5Python Data Science Essentials Rating: 0 out of 5 stars0 ratingsBayesian Analysis with Python Rating: 5 out of 5 stars5/5R Graphs Cookbook Second Edition Rating: 3 out of 5 stars3/5Getting Started with Python Data Analysis Rating: 0 out of 5 stars0 ratingsR For Dummies Rating: 4 out of 5 stars4/5
Programming For You
Python: For Beginners A Crash Course Guide To Learn Python in 1 Week Rating: 4 out of 5 stars4/5Java for Beginners: A Crash Course to Learn Java Programming in 1 Week Rating: 5 out of 5 stars5/5Python Programming : How to Code Python Fast In Just 24 Hours With 7 Simple Steps Rating: 4 out of 5 stars4/5SQL: For Beginners: Your Guide To Easily Learn SQL Programming in 7 Days Rating: 5 out of 5 stars5/5Grokking Algorithms: An illustrated guide for programmers and other curious people Rating: 4 out of 5 stars4/5Python: Learn Python in 24 Hours Rating: 4 out of 5 stars4/5Learn SQL in 24 Hours Rating: 5 out of 5 stars5/5HTML & CSS: Learn the Fundaments in 7 Days Rating: 4 out of 5 stars4/5Excel : The Ultimate Comprehensive Step-By-Step Guide to the Basics of Excel Programming: 1 Rating: 5 out of 5 stars5/5Coding All-in-One For Dummies Rating: 4 out of 5 stars4/5Python Essentials Rating: 5 out of 5 stars5/5Modern C++ for Absolute Beginners: A Friendly Introduction to C++ Programming Language and C++11 to C++20 Standards Rating: 0 out of 5 stars0 ratingsSQL QuickStart Guide: The Simplified Beginner's Guide to Managing, Analyzing, and Manipulating Data With SQL Rating: 4 out of 5 stars4/5SQL All-in-One For Dummies Rating: 3 out of 5 stars3/5Learn PowerShell in a Month of Lunches, Fourth Edition: Covers Windows, Linux, and macOS Rating: 0 out of 5 stars0 ratingsLearn to Code. Get a Job. The Ultimate Guide to Learning and Getting Hired as a Developer. Rating: 5 out of 5 stars5/5PYTHON: Practical Python Programming For Beginners & Experts With Hands-on Project Rating: 5 out of 5 stars5/5Python QuickStart Guide: The Simplified Beginner's Guide to Python Programming Using Hands-On Projects and Real-World Applications Rating: 0 out of 5 stars0 ratingsLinux Command Line and Shell Scripting Bible Rating: 3 out of 5 stars3/5The Absolute Beginner's Guide to Binary, Hex, Bits, and Bytes! How to Master Your Computer's Love Language Rating: 5 out of 5 stars5/5Python Machine Learning By Example Rating: 4 out of 5 stars4/5HTML in 30 Pages Rating: 5 out of 5 stars5/5Photoshop For Beginners: Learn Adobe Photoshop cs5 Basics With Tutorials Rating: 0 out of 5 stars0 ratingsProblem Solving in C and Python: Programming Exercises and Solutions, Part 1 Rating: 5 out of 5 stars5/5
Reviews for R Programming - a Comprehensive Guide
0 ratings0 reviews
Book preview
R Programming - a Comprehensive Guide - Editor IJSMI
Chapter 1 – Introduction
Ris a programming language and environment which is widely used in different fields. It was developed by Ross Ihaka and Robert Gentleman from University of Auckland. R is one of the versions of S language which is developed by the Bell laboratories in United States of America.
R core development team monitors the development process. R language contents are updated by its vast community of users through the modules called ‘packages’. R language is frequently updated and the recent version 4.0.0 as of April 2020. R environment has some built in packages and more packages can be downloaded from The Comprehensive R Archive Network (CRAN) website (https://cran.r-project.org/).
R programming is platform independent and can be deployed in any operating system. It is compatible with other languages such as Java and Python programing.
R lets the users to modify the existing packages and allows them to update with their own codes and functions thus offering greater flexibility in programming.
R Programming language is helpful for data handling, data visualization and data analysis capabilities. It also includes reporting and dash board features.
R is mainly useful for carrying out statistical analysis such as descriptive, inferential, regression modelling, clustering, discriminant analysis, factor analysis and survival analysis.
Getting started
R recent version can be downloaded from cran-r project website (https://cran.r-project.org/).
R Environment
The GUI version of R environment
There are Integrated Development Environment is available for R such as R-Studio and Rattle which provides Graphical User Interface (GUI) to the R environment. Both the IDEs are also freely available for download.
Apart from the above R Commander an interface for R environment provides GUI as well as menu based application for frequently used functions such as statistical functions along with the facility to write r codes.
R-Studio
Writing code in the R Studio
R studio has the following four default windows (panes) with each having sub tabs in it
Top left
Source
Bottom Left
Console
Terminal
Jobs
Top Right
Environment
History
Connection
Bottom right
Files
Plots
Packages
Help
Viewer
Find out version of R
After installing R and R studio we can what R version we have installed by executing the following code. It also provides the base packages which are attached the R environment. To execute a statement or block of statement we can use the run
symbol in the source window(pane) or(CTRL+enter) to execute the code.
Writing Codes for execution in R studio
Users can start writing their codes or statements in the Ssource window which is located at the top left window.
There are built in functions available in the R ‘base’ package which can be viewed by executing the following help code. One need to invoke the library function to start the execution related to a package
Similarly we can use library (help=stats
) to see the functions associated with the package stats
Getting help
If want to know about any specific package or function we can use the help menu in the right bottom window (pane). We can search using specific function name such as sum in the search box.
Saving R files
By default R programming files are saved with .R extension which is nothing but the R script file. Files can be saved with following extensions also which will be discussed in detail in the later chapters.
.r – R script file
.rmd – R markdown file
.rnw – R Sweave file
Creating working directory
We can set the working directory by using the statement setwd along with the path reference to the working directory.
Installing packages
Packages or modules can be installed using install.packages statement or through R studio’s Tools - install packages menu
Calling packages to the R environment
library statement is used to call the packages into R environment
REFERENCE
https://cran.r-project.org/
R Core Team (2017). R: A language and environment for
statistical computing. R Foundation for Statistical Computing, Vienna, Austria. URL