# NOT RUN {
data(biomass)
biomass_tr <- biomass[biomass$dataset == "Training",]
biomass_te <- biomass[biomass$dataset == "Testing",]
rec <- recipe(HHV ~ carbon + hydrogen + oxygen + nitrogen + sulfur,
data = biomass_tr)
im_trans <- rec %>%
step_YeoJohnson(all_predictors()) %>%
step_center(all_predictors()) %>%
step_scale(all_predictors()) %>%
step_isomap(all_predictors(),
options = list(knn = 100),
num = 2)
im_estimates <- prep(im_trans, training = biomass_tr)
im_te <- bake(im_estimates, biomass_te)
rng <- extendrange(c(im_te$Isomap1, im_te$Isomap2))
plot(im_te$Isomap1, im_te$Isomap2,
xlim = rng, ylim = rng)
tidy(im_trans, number = 4)
tidy(im_estimates, number = 4)
# }
Run the code above in your browser using DataLab