Note that caret and recipes use the BC transform to modify the predictors; it was created as a method for transforming the outcome in a linear regression.
If you're interested in transforming the outcome, I don't think that there is a tidy solution (yet). For the predictors (or any other variables in isolation), recipes is probably your best best. Also, the Yeo-Johnson transformation is the same but allows for negative and zero values in the data too (also in recipes).
Some example code:
> library(recipes)
> set.seed(3215)
> dat <- data.frame(x = exp(rnorm(100)))
>
> head(dat)
x
1 1.156
2 0.326
3 0.584
4 1.025
5 1.736
6 0.840
>
> # create the recipe
> bc_rec <- recipe(~ x, data = dat) %>%
+ # add the transformation
+ step_BoxCox(x) %>%
+ # estimate lambda
+ prep(training = dat, retain = TRUE)
>
> # Now get the transformed value
> trans_dat <- juice(bc_rec)
> trans_dat
# A tibble: 100 x 1
x
<dbl>
1 0.1451
2 -1.0918
3 -0.5308
4 0.0245
5 0.5588
6 -0.1734
7 1.2635
8 -1.2698
9 1.2440
10 0.3316
# ... with 90 more rows
> # lambda estimate:
> tidy(bc_rec, number = 1)
# A tibble: 1 x 2
terms value
<chr> <dbl>
1 x 0.0491