Skip to content
Prev 43307 / 63421 Next

R package dependency issues when namespace is not attached

On 12-05-13 3:15 AM, Jeroen Ooms wrote:
Not sure if it's a bug, but the correct solution in bigdata is to import 
the glmnet function in its NAMESPACE.  Then the namespace that gets 
loaded when you type bigdata::lasso.stars will be able to see the glmnet 
function.

Perhaps Depends in the DESCRIPTION file should do the import 
automatically, but it will be faster to import just one function than 
everything from a package that has a lot of exports.  So maybe it's a 
bug because we don't do that, but I think there would be complaints if 
we did.

On the other hand, if bigdata::lasso.stars loaded glmnet onto the search 
path, I think that would be a bug.  The search path belongs to the user, 
not to R, and the user might have used the :: notation to avoid messing 
with it.

Duncan Murdoch