Skip to main content
HomeR

Course

Machine Learning with Tree-Based Models in R

BasicSkill Level
4.8+
234 reviews
Updated 08/2023
Learn how to use tree-based models and ensembles to make classification and regression predictions with tidymodels.
Start Course for Free
RMachine Learning4 hr16 videos58 Exercises4,850 XP10,531Statement of Accomplishment

Create Your Free Account

or

By continuing, you accept our Terms of Use, our Privacy Policy and that your data is stored in the USA.

Loved by learners at thousands of companies

Group

Training 2 or more people?

Try DataCamp for Business

Course Description

Tree-based machine learning models can reveal complex non-linear relationships in data and often dominate machine learning competitions. In this course, you'll use the tidymodels package to explore and build different tree-based models—from simple decision trees to complex random forests. You’ll also learn to use boosted trees, a powerful machine learning technique that uses ensemble learning to build high-performing predictive models. Along the way, you'll work with health and credit risk data to predict the incidence of diabetes and customer churn.

Prerequisites

Modeling with tidymodels in R
1

Classification Trees

Ready to build a real machine learning pipeline? Complete step-by-step exercises to learn how to create decision trees, split your data, and predict which patients are most likely to suffer from diabetes. Last but not least, you’ll build performance measures to assess your models and judge your predictions.
Start Chapter
2

Regression Trees and Cross-Validation

Ready for some candy? Use a chocolate rating dataset to build regression trees and assess their performance using suitable error measures. You’ll overcome statistical insecurities of single train/test splits by applying sweet techniques like cross-validation and then dive even deeper by mastering the bias-variance tradeoff.
Start Chapter
3

Hyperparameters and Ensemble Models

Time to get serious with tuning your hyperparameters and interpreting receiver operating characteristic (ROC) curves. In this chapter, you’ll leverage the wisdom of the crowd with ensemble models like bagging or random forests and build ensembles that forecast which credit card customers are most likely to churn.
Start Chapter
4

Boosted Trees

Ready for the high society of tree-based models? Apply gradient boosting to create powerful ensembles that perform better than anything that you have seen or built. Learn about their fine-tuning and how to compare different models to pick a winner for production.
Start Chapter
Machine Learning with Tree-Based Models in R
Course
Complete

Earn Statement of Accomplishment

Add this credential to your LinkedIn profile, resume, or CV
Share it on social media and in your performance review
Enroll Now

Don’t just take our word for it

*4.8
from 234 reviews
89%
10%
1%
0%
0%
  • Napaporn
    13 hours ago

  • Samantha
    2 days ago

  • shaquile
    2 days ago

    it was really helpful

  • Carlos
    6 days ago

    Gostei!!!

  • Jason
    last week

    gg

  • TingTing
    last week

Napaporn

Samantha

"it was really helpful"

shaquile

FAQs

Does this course use the tidymodels framework for building tree-based models?

Yes. You will use the tidymodels package throughout the course to build, train, and evaluate decision trees, random forests, and boosted tree models in R.

What datasets are used in this course?

You will work with health data to predict diabetes incidence and credit risk data to predict customer churn, applying different tree-based models to each problem.

Does the course cover both classification and regression trees?

Yes. The first chapter focuses on classification trees for predicting diabetes, and the second chapter covers regression trees using a chocolate rating dataset.

What is the most advanced model type taught in this course?

Boosted trees are the most advanced technique covered. You will learn how ensemble learning through boosting builds high-performing predictive models from weaker learners.

What background in R do I need for this course?

You should have completed Introduction to the Tidyverse, Data Manipulation with dplyr, and Modeling with tidymodels in R before starting this beginner-level ML course.

Join over 19 million learners and start Machine Learning with Tree-Based Models in R today!

Create Your Free Account

or

By continuing, you accept our Terms of Use, our Privacy Policy and that your data is stored in the USA.

Grow your data skills with DataCamp for Mobile

Make progress on the go with our mobile courses and daily 5-minute coding challenges.