
This course includes our updated coding exercises so you can practice your skills as you learn.
See a demo
Learn theory and practice of data science from data wrangling to modeling, with hands-on coding in R, covering linear and logistic regression, decision trees, random forests, and end-to-end Kaggle project.
Install R and RStudio to set up your data science environment, download the Windows installer, and explore the R console and RStudio for coding and data analysis.
Install and launch the free R Studio desktop for Windows, explore its console, environment, and script panes, and learn to run commands and manage data frames.
Learn how to install and load external libraries in R, understand dependencies, and use package ecosystems like ggplot and tidyverse to extend data analysis.
Load external libraries to access functions from packages in your script and environment. Always load libraries at the top of your script and reload them when you reopen your session.
The instructor steps away from the bottom corner to focus on the plots, guiding you through voice-only explanations and previewing future slide lectures.
Explore the dplyr library for data wrangling in R, learning how to manipulate data frames with pipes, use filter, arrange, mutate, select, sample, summarise, and joins on the starwars data.
Explore the Deployer library, a data wrangling tool in the tidy collection of packages, and learn how tibbles differ from data frames using the Star Wars data set.
Filter a Star Wars data frame with height over 100 using dplyr's filter and the pipe format to chain operations.
Use glimpse to view a table’s rows and columns, then learn why tibble data frames handle list-type columns like films better than traditional data frames.
Learn how the Deployer Library uses pipes to encapsulate functions, filter by eye color and mass, and count results, illustrating function encapsulation and multiple arguments in filters.
Arrange data frames with the pipe to sort by height (ascending or descending) and mutate to create new columns, including sorts by two variables.
learn to use select and distinct to subset columns and reveal unique values in the starwars data frame, chaining commands with pipes for readability, and compare with non-pipe syntax.
Learn to sample a data frame using sample and sample_frac, control reproducibility with set.seed, and understand how percentage-based sampling yields reproducible subsets for analysis.
Learn to use summarize to aggregate data by group, calculating mean, max, and min, and apply group_by on starwars data to compute mean height by eye color.
Explore joining data frames with the deployer library, performing inner, left, right, and full joins on the species key to combine Star Wars and origin tables.
Learn to complete and debug coding exercises on Udemy platform as part of the data science bootcamp, using vector examples to sum ages, access solutions, and avoid common compiling errors.
Explore linear regression, a simple, interpretable algorithm for predicting continuous variables like house prices. Learn the line equation y = beta1 x + intercept and how least squares minimizes error.
Learn how linear regression minimizes mean squared error using gradient descent or a closed-form solution, and train models to predict continuous variables like mpg from car features.
Explore the linear regression model as the first tool for solving regression problems that predict a continuous variable from features, with data visualization to clarify which variable to predict.
Set up your R working directory, load the salary data into a data frame, fix the semicolon separator, and plot age against monthly salary to explore one-variable regression.
Plot age against monthly salary to gain insight and predict salary from age using linear regression, a supervised learning approach that shows the potential relationship.
Learn how linear regression uses a line with slope m and intercept b to predict salary from age, minimize error, and identify a bad fit when the line misses data.
Adjust the linear model by tweaking weights, learn beta zero and beta one, and observe improved salary predictions and line fitting; preview gradient descent for weight optimization in linear regression.
train your first linear model to predict monthly salary from age by optimizing coefficients with a cost function and comparing the optimized line to the initial line.
Explore how to evaluate linear regression by inspecting residuals, coefficients, p-values, r-squared, and adjusted r-squared, and compare closed-form solutions with gradient descent to estimate weights.
Learn how the closed form solution yields the optimal weights and intercept for linear regression using a matrix approach, illustrated with univariate and multivariate examples.
Explore gradient descent intuition beyond closed-form solutions, visualizing how gradient descent optimizes weights for predicting salary from age, and explain the cost function and squared error guiding optimization.
Explore gradient descent intuition by building a variable beta one, computing the cost function J over a beta landscape, and locating the minimum that matches the linear regression solution.
Visualize gradient descent as it optimizes multiple weights in linear and multivariate regression, guided by the gradient and learning rate to reach a global minimum while avoiding local minima.
Explore multivariate regression by predicting monthly salary from age and education level, visualize with 3D plots, compare univariate and multivariate models, and interpret r-squared, adjusted r-squared, and residuals.
Learn how to solve classification problems with logistic regression by using a sigmoid function to map weighted inputs to a 0–1 probability and optimize the weights for accurate classification.
Explore logistic regression for binary classification, using log loss, sigmoid predictions, and gradient descent to fit models with a binomial family.
Explore classification problems in supervised learning, focusing on binary classification with examples like cat vs dog and fraudulent vs non-fraudulent transactions, and introduce logistic regression as a simple linear model.
Explore classification intuition with a toy fraud dataset, using hour as a predictor; show linear regression's unfitness for fraud classification and introduce the sigmoid function to map to fraud probability.
Implement and visualize the sigmoid function, then fit a logistic regression using a generalized linear model with a binomial family and log loss for binary classification.
Explore logistic regression for binary classification, using sigmoid probabilities to flag fraudulent transactions, evaluate with accuracy and confusion matrix, compare models via AIC, and learn gradient descent for optimization.
Explore the log loss function for logistic regression, i.e., binary cross-entropy, and how it penalizes misclassifications. Visualize sigmoid predictions on fraud data and optimize the beta parameters to minimize loss.
Explore how gradient descent drives classification by evaluating sigmoid predictions and log loss across beta parameters. See how simulations reveal which betas minimize error.
Visualize the log-loss surface in three dimensions for beta zero and beta one, showing how gradient descent moves toward the minimum to improve logistic regression coefficients.
Learn how to evaluate regression and classification models using training and test sets, bias and variance, and metrics such as mean squared error, mean absolute error, and ROC AUC.
Explore linear and logistic regression for regression and classification, including cost functions and model weights, and learn the importance of test-set evaluation, bias, and variance for future predictions.
Explore how a simple linear regression predicts production from rotation using machine one data and reveal the high bias model, its errors, and implications of bias and variance.
Explore how a high variance model overfits a linear relationship, then improve with polynomial features like rotation squared and rotation cubed, while emphasizing evaluation beyond training data.
Explore how to evaluate models on unseen data to prevent overfitting, balance bias and variance, and choose the best model for production through train and test split.
Learn how to perform a randomized train and test split to evaluate machine learning models, ensure reproducibility with a seed, and compare training versus test performance.
Explore training versus test data performance using polynomial terms and R-squared, revealing overfitting risks and how to select models based on test data performance.
Learn regression evaluation beyond r-squared, including residual plots and histogram analysis, in the data science bootcamp course using a house price dataset.
Use mean squared error (MSE) as a regression cost function, penalizing large residuals, and compare it with mean absolute error (MAE) and RMSE for interpretability and model evaluation.
Learn how R-squared and MAPE evaluate regression models, compare against the mean, and assess training versus test performance with residuals and adjusted R-squared.
Learn classification metrics with logistic regression on the Titanic survival dataset, handle missing data via mean imputation, perform a train-test split, and evaluate predictions with a confusion matrix.
Identify true positives, false positives, true negatives, and false negatives within a confusion matrix, and learn how these values assess and drive the metrics that measure your model's performance.
Explore precision, recall, and F-score derived from the confusion matrix, compare accuracy under class imbalance, and learn to use ROC AUC to evaluate models without fixed thresholds.
Learn to build the ROC curve and compute the area under the curve (AUC) to evaluate classification models across thresholds, using sensitivity (recall) and specificity from confusion matrices.
learn how to evaluate models using the rocr package to compute the area under the roc curve (auc) and compare true positive rates and false positive rates with probabilistic predictions.
Explore how decision trees handle nonlinear classification problems, using an ostrich egg weight example to show root and branches, impurity and Gini impurity, and how splits affect outcomes.
Learn to build decision trees by selecting thresholds that minimize impurity via Gini impurity, split data, and grow nodes, using hyperparameters like max depth and min split to prevent overfitting.
Compare logistic regression with tree-based models to show how decision trees classify valid vs not valid packages, addressing linear model limitations.
Demonstrate building a decision tree by selecting thresholds, evaluating splits with Gini impurity, and using a train-test split to refine a model beyond logistic regression.
Explore how to choose the best threshold to minimize Gini impurity in a classification tree, evaluating thresholds across two variables, and visualizing impurity to guide the first split.
Train a one-level classification tree in rpart, using an impurity-based cost function to choose splits, and learn recursive splitting with minimum samples per leaf to prevent overfitting.
Learn how to extend a decision tree with additional thresholds, split data by impurity-minimizing criteria, and visualize classification boundaries to separate classes.
Analyze classification trees by tweaking hyper parameters, evaluating accuracy on a test set, and managing overfitting by controlling the number of levels and splits based on impurity.
Explore regression trees for predicting house prices from area, using threshold splits and mean-price predictions to capture non-linear patterns that linear regression misses.
Analyze regression trees by calculating residual sum of squares, using step function predictions, and evaluating mean and root mean square errors to optimize thresholds.
Explore regression trees by building a function to compute the residual sum of squares for splits, then evaluate thresholds and find the best first split around 55 to 60.
Learn how regression trees fit data using ANOVA-based splits and the sum-of-squares criterion to predict continuous values. Compare to classification trees, where outputs are averages, not probabilities, guided by hyperparameters.
Compare a decision tree with linear regression, adjust the complexity parameter to balance depth and r-squared, and evaluate training versus test performance.
Discover how random forests improve robustness by averaging multiple decision trees for classification and regression, and learn key hyperparameters like number of trees and bootstrap.
Explore how random forest ensembles multiple decision trees, aggregates predictions via voting, and uses mean imputation and data subsetting on Titanic for classification.
Explore how varying thresholds and hyperparameters shape decision trees built from different training data, showing three distinct models with different depths, splits, and purity-driven rules.
Build a random forest with three estimators, plot roc curves from true positive rate and false positive rate, and show how averaging the three trees improves area under the curve.
Measure the accuracy of each decision tree and the ensemble average, compare individual trees to the random forest approach, and anticipate improvements with many trees.
Learn to build random forests in R using the randomForest package, tune hyperparameters like number of trees and max nodes, and evaluate Titanic survival predictions on test data.
Explore a practical framework for starting data science projects, from data collection and wrangling to feature engineering, exploratory data analysis, and building a first baseline model.
Begin a data science project predicting taxi trip duration in a Kaggle-style competition, covering preprocessing, feature engineering, modeling linear regression and random forest, evaluated by root mean squared logarithmic error.
Load and inspect a large taxi trip dataset, identify outliers in coordinates and trip duration, analyze distributions, and apply distribution-based filtering to clean data for modeling.
Explore removing outliers using a distribution-based approach by filtering data with mean plus/minus three standard deviations for variables like pickup longitude and latitude, to improve regression robustness.
Build time-based features from pickup time, such as month, day, and hour, to analyze taxi trip duration and guard against target leakage while iterating with outlier-filtered data.
Visualize mean trip duration by month, day, and hour to reveal cycles; plan sine cosine transformations and distance-based features from longitude and latitude for predictive modeling.
Learn feature engineering using latitude and longitude to build Manhattan and Euclidean distance features for predicting taxi trip duration, with distance formulas and model choices like random forest.
Learn feature engineering by creating Manhattan and Euclidean distance features from taxi pickup and dropoff coordinates, visualizing correlations, and enriching data tables for modeling in a data science bootcamp.
Create a weekday feature from pickup times and build a reusable data pipeline that applies Manhattan and Euclidean distance functions to generate robust features for future models.
Prepare taxi data for modelling by one-hot encoding weekdays and converting text to numeric, then build models with Kerith Carrot to predict taxi trip duration using pickup time and distances.
Train a baseline linear model to predict trip duration from 15 features, evaluate R-squared and root mean squared error on train and test data, then compare with a random forest.
Compare linear models with a random forest to show improved handling of cyclical hours, using Ranger for fast training and assessing overfitting and future hyperparameter tuning.
Explore the caret API for model training, using the train function with a method parameter to switch between Ranger and GLM and tune hyperparameters.
Explore hyperparameter tuning by building a parameter grid for a random forest, configuring cross-validation and train control, and running multiple experiments to identify the best settings.
Evaluate and tune hyperparameters of a random forest model using cross-validation to improve rmse and r-squared. Save, serialize, and load the best model for predicting new data and evaluating performance.
Evaluate the saved model on unseen Kaggle test data. Build feature engineering with distance and time features, then predict trip durations.
Learn to submit predictions to competition platform by creating a two-column file with trip duration and predicted duration, using a baseline model with feature engineering to evaluate and improve results.
So are you looking to jump into one of the most exciting fields to work on today? And are you looking for a course that explains all the theory behind algorithms with coding?
This course was designed to be your first complete step into Data Science! We will delve deeper into the concepts of Linear and Logistic Regression, understand how Tree Based models work and learn how to evaluate predictive models. Additionally, you will develop your first end-to-end kaggle project!
This course contains lectures around the following groups:
Code along lectures where you will see how we can implement the stuff we will learn;
Test your knowledge with questions and practical exercises with different levels of difficulty;
This course was designed to be focused on the practical side of coding in R - other than studying the functions that let us build algorithms automatically we will investigate deeply how models are trained and how they get to the optimum solution to solve our data science challenges. And why will we use R?
R is one of the de facto languages for a lot of Data Science projects today - either for enterprise-level projects or research, R is a modern and flexible language with a smooth learning curve that enables most professionals to build predictive models in quick fashion.
At the end of the course you should be able to contribute to data science projects - understanding the choices you have to make when it comes to algorithms and learn how to evaluate those choices. Along the way you will also learn how to manipulate data with Dplyr because a huge percentage of the time spent in a Data Science project is focused on data preparation!
Here are some examples of things you will be able to do after finishing the course:
Solving Regression problems using Linear Regression or Regression Trees.
Solving Classification problems using Logistic Regression or Classification Trees.
Learn how to evaluate algorithms using different metrics.
Understanding the concept of bias and variance.
Using Random Forests and understanding the reasoning behind them.
Manipulating data using Dplyr.
Build your own Kaggle Data Science project!
Join thousands of professionals and students in this Data Science journey and discover the amazing power of R as a statistical open-source language.
This course will be constantly updated based on students feedback.