From 81db2c85f443760b198eb8023a60d01c2dfe48b3 Mon Sep 17 00:00:00 2001 From: Jasleen Sondhi Date: Sun, 17 Sep 2023 03:25:53 +0530 Subject: [PATCH] fixed spacing --- 2-Regression/4-Logistic/solution/R/lesson_4.Rmd | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/2-Regression/4-Logistic/solution/R/lesson_4.Rmd b/2-Regression/4-Logistic/solution/R/lesson_4.Rmd index 7f5357e6..18407b31 100644 --- a/2-Regression/4-Logistic/solution/R/lesson_4.Rmd +++ b/2-Regression/4-Logistic/solution/R/lesson_4.Rmd @@ -82,8 +82,6 @@ There are other types of logistic regression, including multinomial and ordinal: ![Multinomial vs ordinal regression](https://github.com/microsoft/ML-For-Beginners/blob/main/2-Regression/4-Logistic/images/multinomial-vs-ordinal.png) -\ - #### **Variables DO NOT have to correlate** @@ -306,6 +304,7 @@ log_reg_wf After a workflow has been *specified*, a model can be `trained` using the [`fit()`](https://tidymodels.github.io/parsnip/reference/fit.html) function. The workflow will estimate a recipe and preprocess the data before training, so we won't have to manually do that using prep and bake. + ```{r train} # Train the model wf_fit <- log_reg_wf %>% @@ -345,8 +344,6 @@ The [**`conf_mat()`**](https://tidymodels.github.io/yardstick/reference/conf_mat ```{r conf_mat} # Confusion matrix for prediction results conf_mat(data = results, truth = color, estimate = .pred_class) - - ``` Let's interpret the confusion matrix. Our model is asked to classify pumpkins between two binary categories, category `white` and category `not-white`