ryantibs / best-subset

Comparisons between best subset selection and other popular sparse regression estimators
GNU General Public License v2.0
86 stars 35 forks source link

fix the bug: coef.bs can take scalar input s #4

Closed zhan-gao closed 7 years ago

zhan-gao commented 7 years ago

when s is a scalar, beta.mat is not a matrix it causes a bug since ncol(beta.mat) = NULL when beta.mat is a numeric vector

ryantibs commented 7 years ago

Thank you for catching the bug in coef.bs. I just fixed this. As for the intercept, it is already being computed correctly.