# \donttest{
# we first obtain the rankings and object variables
data(ghana)
y <- list(ghana[[1]], ghana[[2]])
x <- ghana[[3]]
# our next step consists of creating two vectors for the penalty parameters
ls_vec <- lf_vec <- c(0, 0.25)
# we choose epsilon to be small: 10^(-5), as we did in Hermes et al., (2024)
# now we can fit our model
epsilon <- 10^(-5)
verbose <- FALSE
result <- sfpl_approx(x, y, ls_vec, lf_vec, epsilon, verbose)
# now we select the best models using our model selection function
sfpl_select(result, x, y, ls_vec, lf_vec)
# }
Run the code above in your browser using DataLab