wush978 / FeatureHashing

Implement feature hashing with R
GNU General Public License v3.0
97 stars 38 forks source link

MLmetrics pkg should be escaped in examples #122

Closed jangorecki closed 7 years ago

jangorecki commented 8 years ago

Hi, Just came to inform that suggested packages used in examples should be escaped, so not mandatory to run examples. Best way is to use if (requireNamespace(.)) {_actual_code_} function. Otherwise you should move MLmetrics (and potentially others, MLmetrics was first to fail) to imports.

* checking examples ... ERROR
Running examples in ‘rFTRLProximal-Ex.R’ failed
The error most likely occurred in:

> ### Name: FTRLProx_cv
> ### Title: FTRL-Proximal Linear Model Cross Validation
> ### Aliases: FTRLProx_cv
> 
> ### ** Examples
> 
> library(FeatureHashing)
> library(data.table)
> library(rBayesianOptimization)
> library(MLmetrics)
Error in library(MLmetrics) : there is no package called ‘MLmetrics’
Execution halted

The best way to check is remove all suggested deps and try R CMD check. More details in R-exts.

wush978 commented 8 years ago

Thanks for your suggestion. I'll check it soon.

wush978 commented 7 years ago

I cannot find any MLmetrics in the documentation. I seems like this should be an issue of the package rFTRLProximal