mboost icon indicating copy to clipboard operation
mboost copied to clipboard

Search for baselearner in this package

Open kenahoo opened this issue 5 years ago • 6 comments

Search for baselearner in this package, not in the caller's namespace.

When baselearner is given as a string, it's limited (by match.arg) to the pre-defined choices c("bbs", "bols", "btree", "bss", "bns"). It doesn't make sense to require the caller to import that symbol when we know it's defined in the mboost package anyway.

In my case, I'm invoking mboost through a third-party package that does cross-validation, so it's impossible for me to import btree into that namespace. The only solution is to do a shotgun library(mboost) to export the btree symbol globally, but I'd like to avoid that.

I also noticed that the bname variable is never used, so I got rid of it.

kenahoo avatar Mar 13 '19 15:03 kenahoo

Coverage Status

Coverage decreased (-0.01%) to 78.621% when pulling 708915f69070c7d65acf3a46cb6e0c02dffc6af9 on kenahoo:patch-1 into f10b45c7f03512cb952d1c7c47dc616f1e678ce0 on boost-R:master.

coveralls avatar Mar 13 '19 15:03 coveralls

Thanks a lot for the patch and sorry for my rather slow response. Time is always (too) scarce. Unfortunately I cannot check the PR on windows as Appveyor is causing problems. Hope it is fixed soon.

hofnerb avatar Mar 22 '19 15:03 hofnerb

Hi @hofnerb , it looks like the Appveyor failure doesn't really have anything to do with this patch, it looks like some configuration problems:

travis-tool.sh install_deps
...
+ Rscript -e 'options(repos=c(CRAN="https://cran.rstudio.com")); remotes::install_deps(dependencies = TRUE, type="both")'
...
Error: (converted from warning) package 'biomaRt' is not available (for R version 3.5.3 Patched)
Execution halted
Command exited with code 1

I think it's trying to install biomaRt from CRAN, but it's a bioconductor package.

kenahoo avatar Apr 12 '19 16:04 kenahoo

@hofnerb about the previous comment - what happens if you move the - travis-tool.sh install_deps line in appveyor.yml to be the last step in build_script, instead of the first step?

kenahoo avatar Apr 15 '19 16:04 kenahoo

Still not working, now due to another issue related to BioC... I was hoping it is working out by the time by itself. Very annoying.

hofnerb avatar Apr 15 '19 16:04 hofnerb

So does this mean no fixes can happen on mboost for the foreseeable future?

kenahoo avatar Apr 22 '19 19:04 kenahoo