From 6e938c36fb729f2bc993da37e5be7bc8505f6658 Mon Sep 17 00:00:00 2001 From: Jasleen Sondhi Date: Tue, 19 Sep 2023 21:21:14 +0530 Subject: [PATCH] fixed plot and modelling error --- 2-Regression/4-Logistic/solution/R/lesson_4.Rmd | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/2-Regression/4-Logistic/solution/R/lesson_4.Rmd b/2-Regression/4-Logistic/solution/R/lesson_4.Rmd index 16610df37..971fc56ba 100644 --- a/2-Regression/4-Logistic/solution/R/lesson_4.Rmd +++ b/2-Regression/4-Logistic/solution/R/lesson_4.Rmd @@ -188,10 +188,11 @@ Amazing🤩! For some of the features, there's a noticeable difference in the di palette <- c(ORANGE = "orange", WHITE = "wheat") # We need the encoded Item Size column to use it as the x-axis values in the plot -pumpkins_select$item_size <- baked_pumpkins$item_size +pumpkins_select_plot<-pumpkins_select +pumpkins_select_plot$item_size <- baked_pumpkins$item_size # Create the grouped box plot -ggplot(pumpkins_select, aes(x = `item_size`, y = color, fill = color)) + +ggplot(pumpkins_select_plot, aes(x = `item_size`, y = color, fill = color)) + geom_boxplot() + facet_grid(variety ~ ., scales = "free_x") + scale_fill_manual(values = palette) + @@ -296,6 +297,7 @@ wf_fit <- log_reg_wf %>% # Print the trained workflow wf_fit + ``` The model print out shows the coefficients learned during training.