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

Error when a single lambda value is specified in ncvsurv() #5

Closed
nanxstats opened this issue Dec 24, 2016 · 0 comments
Closed

Error when a single lambda value is specified in ncvsurv() #5

nanxstats opened this issue Dec 24, 2016 · 0 comments

Comments

@nanxstats
Copy link

Example code to reproduce the error:

library("ncvreg")
data("Lung")
X = Lung$X
y = Lung$y

fit = ncvsurv(X, y, penalty = 'MCP',  alpha = 1, gamma = 3,
              lambda = c(0.05, 0.01))  # good
fit = ncvsurv(X, y, penalty = 'MCP', alpha = 1, gamma = 3,
              lambda = 0.01)  # error

the latter will throw an error from sweep():

Error in array(STATS, dims[perm]) : 'dims' cannot be of length 0

Seems to be introduced in: 9e8d9ea#diff-a2e9542b122c6bcb8ed0418530b4808aL90

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

1 participant