Giảm Chiều Dữ Liệu với R
Matt Pickard
Owner, Pickard Predictives, LLC
healthcare_df %>% select(where(is.numeric)) %>%correlate() %>%shave() %>%rplot(print_cor = TRUE) +theme(axis.text.x = element_text(angle = 90, hjust = 1))






# tạo và chuẩn bị recipe corr_recipe <- recipe(Attrition ~ ., data = healthcare_df) %>%step_corr(all_numeric_predictors(), threshold = 0.7) %>%prep()# Áp dụng recipe cho dữ liệu filtered_healthcare_df <- corr_recipe %>% bake(new_data = NULL)# Xác định các đặc trưng đã bị loại tidy(corr_recipe, number = 1)
Giảm Chiều Dữ Liệu với R