MulaiMulai sekarang secara gratis

Random grid search

The most common method of hyperparameter tuning is grid search. This method creates a tuning grid with unique combinations of hyperparameter values and uses cross validation to evaluate their performance. The goal of hyperparameter tuning is to find the optimal combination of values for maximizing model performance.

In this exercise, you will create a random hyperparameter grid and tune your loans data decision tree model.

Your cross validation folds, loans_folds, workflow object, loans_tune_wkfl, custom metrics function, loans_metrics, and dt_tune_model have been loaded into your session.

Latihan ini adalah bagian dari kursus

Modeling with tidymodels in R

Lihat Kursus

Latihan interaktif praktis

Cobalah latihan ini dengan menyelesaikan kode contoh berikut.

# Hyperparameter tuning with grid search
set.seed(214)
dt_grid <- ___(___(___),
               size = ___)

dt_grid
Edit dan Jalankan Kode