
Read flat data files into R, build loops and functions, and wrangle data into clean structures. Generate summaries, create storytelling visualizations, test hypotheses, and compare regression models.
Start by installing R and RStudio, explore the RStudio interface with main windows and tabs, set and check your working directory, and personalize the appearance for focused data science work.
Download and install R from CRAN using a preferred mirror for Windows, Mac, or Linux. Then install RStudio as a front end and IDE to work with R.
Explore the RStudio GUI, console, environment/history pane, files pane, code completion, and the script pane to run commands and organize your work.
Personalize your RStudio appearance to reduce eye strain by using Tools, global options, and the appearance tab, selecting Solarized Dark or cobalt, and adjusting font size and Consolas.
Install and load R packages such as ggplot2 to extend functionality, using install.packages and library, and explore CRAN, the packages tab, and task views to find the right tools.
Explore vectors in R, focusing on integers and doubles; learn the L suffix for integer vectors, why doubles are default, and how to inspect objects with type and ls.
Learn how R coerces vector elements to a common type: a single character string makes all elements characters, and logicals convert to ones and zeros when paired with numbers.
Explore how objects and functions interact in R, run functions with arguments, and save results to objects for reuse, using mean and round examples and printing outcomes.
Explore how functions in R take multiple arguments and how to inspect them with args, including optional digits in rounding. Learn why naming arguments prevents misalignment.
Build your first R function to draw three cards from a five-character deck using sample with replace, encapsulating deck creation, sampling, and printing the hand.
Learn why using the script editor in RStudio offers durable code, easy execution with ctrl/cmd+return, and clearer syntax error feedback, making beginners safer and more productive.
Learn to create and name vectors, perform vector arithmetic, index elements, and use vector recycling, then reshape into a two-dimensional object and explore matrices and R's help pane.
Learn how vectors in R are same-type sequences and perform element-wise arithmetic, using functions like mean, median, sd, min, max, sum, and product, with references to R Reference Card 2.0.
Discover how R performs vector recycling by repeating the shorter vector to match lengths, enabling elementwise operations on unequal-length vectors.
Learn how to name vectors in R by assigning, checking, and overwriting the names attribute, and removing names to manage vector attributes effectively.
Learn to access R help pages with ?function, navigate package documentation, and explore sections like description, usage, arguments, details, value, see also, and examples, using keyword search.
Learn to index and slice vectors in R by position and by name, using minus signs and logical comparisons, with numeric and character vectors as examples.
Use the dim function to turn a vector into a three by four matrix, observe column-major filling, and note how changing dimensions alters the object's class while preserving its type.
Explore matrices as two-dimensional extensions of vectors, create them with the matrix function (nrow/ncol) or with rbind and cbind, and use row names and transpose to orient data.
Explore how matrices in R recycle values to fill a given dimension by repeating a vector. Note a warning if the vector length isn't a multiple of rows.
Learn to subset and index a matrix in R by selecting single values, entire rows, and columns, converting results to vectors and understanding two-dimensional indexing.
Slice matrices in R by indexing rows and columns with a position vector and a trailing comma, then subset by row and column names.
Explore matrix arithmetic through element-wise operations on matrices, including scalar division, recycling vectors to form matrices, subtracting budgets to compute margins, and inner versus outer multiplication with t.
learn to compute column sums and row means in a matrix, then save results as vectors and bind them into a new matrix using rbind and cbind, for data insights.
Explore categorical variables, levels, and the distinction between ordinal and nominal data with examples like education and ethnicity. Learn how R uses the factor function to create factor variables.
Learn to convert a character vector to a factor, set levels and labels, and order levels for ordinal data using the factor function and levels in R.
Explore lists in R, a recursive vector that stores heterogeneous objects and hierarchies. Create and name lists using list and names, and subset them with single or double brackets.
Explore relational and logical operators in R, covering the six comparison operators (==, !=, <, >, <=, >=), their use with numbers, logicals, characters, and dataframes, and boolean coercion.
Master boolean operators in R, including and, or, and not, to combine comparisons and filter data with practical examples.
Learn how relational and logical operators work with vectors in R, performing element-wise comparisons and combining results with and, or, and not.
Learn if, else, and else if statements in R to branch decisions based on conditions, understand syntax, and manage vector logic and multiple scenarios.
Explains how if, else, and else if work in R, showing that a condition is a value, that a vector uses first true value, and that first true condition executes.
Discover how for loops in R automate tasks by iterating over values with a clear initiation, decision, and body, following the idea 'for every value of x, do y'.
Learn how while loops in R run while a condition is true, updating values to stop when the condition becomes false, for non-fixed iterations and dynamic conditions.
Explore repeat loops in R, learning that the condition comes after execution and a break stops iterations, then compare with for and while loops, and saving results externally.
Learn to redefine a simple function in R as a flexible tool using arguments, decks, and dealing cards; implement shuffling to ensure random hands and apply to different datasets.
Explore environments and scoping in R, learning how local and global scopes shape function results, use return, define default arguments, and nest shuffle and deal functions.
Learn to create and import dataframes into R, inspect them with str and summary, access individual elements, extend with new observations or variables, handle missing data, and export results.
Create data frames by binding equal-length vectors into columns, allowing data types to differ between columns but remain consistent within each column.
Explore the tidyverse master package and its core tools—ggplot2, dplyr, readr, tibble, and purrr—to speed up data manipulation, analysis, and visualization with common APIs.
Import data into R with read.table function, specifying separator, header, and strings factors. Set and check the working directory, and load text and CSV files.
Learn how to import csv files in R using read.csv, compare with read.table, set headers, choose separators, and control data import with nrow and skipping lines.
Export your data from R to csv or tab-delimited text using write.csv and write.table, naming the file with a .csv extension and setting row.names = FALSE to prevent extra columns.
Explore subsetting data frames in R with tidyverse tools and the Star Wars tibble. Use square-bracket, dollar, and double-bracket indexing, and the combine function to select multiple columns.
Extend a data frame in R by adding columns with dollar sign, double brackets, or cbind. Bind one-row data frames to add rows, and ensure names match when combining.
Detect missing values in R using is.na and any, then replace NAs with unknown or with a column mean or median. Learn to clean data frames and subset results.
Learn data transformation with dplyr, mastering filter, arrange, mutate, and transmute, plus sampling and tidy data concepts; tidy real datasets with gather, spread, separate, unite, and the pipe operator.
Explore data transformation in R with the dplyr package on the Star Wars dataset, using filter, select, mutate, transmute, and everything to shape and summarize data with tibbles.
Learn how to transform data with the dplyr package in R, applying filtering, selecting, mutating, and arranging by mass, then group by species and summarize with averages.
Explore dplyr's sample_n and sample_frac for random samples. Use replace = TRUE for bootstrapping and estimate confidence intervals; prepare for the pipe operator.
Learn how the R pipe operator unites and separates operations to build a readable data pipeline, applying group by, summarize, and filter to Star Wars data.
Master tidy data concepts and the tidy R package approach using gather and separate in R. Apply these tools to tidy messy data and extract clean week and rank variables.
Learn to unite two columns and spread data to tidy weather data in R, turning daily tmin and tmax into a wide, single-row representation.
Begin learning data visualization with ggplot2, mastering the grammar of graphics and the seven layers as you create histogram, bar chart, box-and-whisker, and scatter plots using Titanic data.
Explore data visualization with the ggplot2 package in R and apply the grammar of graphics seven layers—data, aesthetics, geometries, facets, stats, coordinates, and themes.
Explore the grammar of graphics with ggplot2 in R, building layered plots from data and aesthetics to geometry, facets, stats, coordinates, and themes, using CPI and HDI datasets.
Review categorical and numerical data, distinguish discrete and continuous variables, and recall nominal, ordinal, interval, and ratio types using noir, with histogram plots and Kelvin-based temperature examples.
Explore building histograms with ggplot2 to reveal the age distribution of Titanic passengers, adjusting bins, colors, transparency, and labels for publication-ready visualizations.
Learn to create bar charts for a single categorical variable with ggplot2, mapping aesthetics like fill by survived or gender, and faceting by passenger class to explore survival patterns.
Build a ggplot2 box plot of a continuous variable grouped by survived, showing quartiles, medians, and outliers, with jittered points by gender to reveal distributions.
Explore how to build and enhance a scatterplot in ggplot2 by mapping two numerical variables: corruption perception index and human development index, by region, with customization options and trend lines.
Differentiate population from sample and define parameters and statistics, then choose a random, representative sample to inform reliable inferences.
Explore the mean, median, and mode as central tendency measures, their upsides and limitations with outliers, and how to identify them using data via contingency tables like pizza prices.
Explore skewness as a measure of data asymmetry in R, linking mean, median, and mode to right, left, and zero skew through histograms and outliers.
Learn variance, standard deviation, and the coefficient of variation as univariate dispersion measures, understand sample formulas, and compute them in R using apply on a pizza data frame.
Explore covariance and the correlation coefficient to assess the relationship between land value and structure cost, using scatter plots and R's stats functions for interpretation and tests.
R Programming for Statistics and Data Science 2023
R Programming is a skill you need if you want to work as a data analyst or a data scientist in your industry of choice. And why wouldn't you? Data scientist is the hottest ranked profession in the US.
But to do that, you need the tools and the skill set to handle data. R is one of the top languages to get you where you want to be. Combine that with statistical know-how, and you will be well on your way to your dream title.
This course is packing all of this, and more, in one easy-to-handle bundle, and it’s the perfect start to your journey.
So, welcome to R for Statistics and Data Science!
R for Statistics and Data Science is the course that will take you from a complete beginner in programming with R to a professional who can complete data manipulation on demand. It gives you the complete skill set to tackle a new data science project with confidence and be able to critically assess your work and others’.
Laying strong foundations
This course wastes no time and jumps right into hands-on coding in R. But don’t worry if you have never coded before, we start off light and teach you all the basics as we go along! We wanted this to be an equally satisfying experience for both complete beginners and those of you who would just like a refresher on R.
What makes this course different from other courses?
Well-paced learning.
Receive top class training with content which we’ve built - and rigorously edited - to deliver powerful and efficient results.
Even though preferred learning paces differ from student to student, we believe that being challenged just the right amount underpins the learning that sticks.
Introductory guide to statistics.
We will take you through descriptive statistics and the fundamentals of inferential statistics.
We will do it in a step-by-step manner, incrementally building up your theoretical knowledge and practical skills.
You’ll master confidence intervals and hypothesis testing, as well as regression and cluster analysis.
The essentials of programming – R-based.
Put yourself in the shoes of a programmer, rise above the average data scientist and boost the productivity of your operations.
Data manipulation and analysis techniques in detail.
Learn to work with vectors, matrices, data frames, and lists.
Become adept in ‘the Tidyverse package’ - R’s most comprehensive collection of tools for data manipulation – enabling you to index and subset data, as well as spread(), gather(), order(), subset(), filter(), arrange(), and mutate() it.
Create meaning-heavy data visualizations and plots.
Practice makes perfect.
Reinforce your learning through numerous practical exercises, made with love, for you, by us.
What about homework, projects, & exercises?
There is a ton of homework that will challenge you in all sorts of ways. You will have the chance to tackle the projects by yourself or reach out to a video tutorial if you get stuck.
You: Is there something to show for the skills I will acquire?
Us: Indeed, there is – a verifiable certificate.
You will receive a verifiable certificate of completion with your name on it. You can download the certificate and attach it to your CV and even post it on your LinkedIn profile to show potential employers you have experience in carrying out data manipulations & analysis in R.
If that sounds good to you, then welcome to the classroom :)