@config holds what the user asked for and @values what preprocessing
learned, which keeps the input intact – but re-applying to new data needs
the two merged, and so does a run record, which must report the values
actually used. One merge, so the two cannot disagree.
Details
The merged fields are settable inputs: supplying scale_centers makes
preprocess() use it instead of computing one. That is why the merge is
@values over @config and not the reverse – a learned value only fills a
slot the user left empty.
Examples
iris_pre <- preprocess(iris, setup_Preprocessor(scale = TRUE, center = TRUE))#> 2026-10-20 09:07:50
#> Scaling and centering 4 numeric features...
#> [preprocess_data]
#> 2026-10-20 09:07:50
#> Preprocessing done.
#> [preprocess_data]# The config as supplied carries no centers; the fitted one carries the
# centers `preprocess()` computed.
fitted_config(iris_pre)@scale_centers#> Sepal.Length Sepal.Width Petal.Length Petal.Width
#> 5.843333 3.057333 3.758000 1.199333