Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lasso Funs and other examples #23

Open
nolanbidleman opened this issue Nov 20, 2023 · 1 comment
Open

Lasso Funs and other examples #23

nolanbidleman opened this issue Nov 20, 2023 · 1 comment

Comments

@nolanbidleman
Copy link

When running examples from the r code folder, examples such as lasso.funs and elastics.funs, I keep getting an error when running it.

funs = lasso.funs(lambda = lambda)
Error in !is.numeric(lambda) || min(lambda) <= 0 || (order(lambda) != :
'length = 96' in coercion to 'logical(1)'

This is the error I am getting when running these functions. Please help out if possible.

@thmild
Copy link

thmild commented Feb 4, 2025

This still persists, same problem here. It seems that in elastic.funs() we need any() in front of (order(lambda) != length(lambda):1)):

if (!is.null(lambda) && (!is.numeric(lambda) || min(lambda) <= 
                           0 || any(order(lambda) != length(lambda):1))) {
    stop("lambda must be a decreasing sequence of positive numbers")
  }

With that simple addition, the example from the conformal.pred help page runs without error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants