koheiw / proxyC

R package for large-scale similarity/distance computation
GNU General Public License v3.0
29 stars 6 forks source link

Allow suppressing NaN warning with `use_nan = FALSE` #39

Closed rcannood closed 1 year ago

rcannood commented 1 year ago

There are some use cases in which I would rather have zeros in the resulting similarity matrix, but don't wish to see the warnings. Rather than use suppressWarnings() to suppress all warnings, I propose explicitly setting use_nan = FALSE results in zeros without any warnings being generated.

I ran revdepcheck to verify this does not break any unit tests of other packages.

I also enabled markdown = TRUE for roxygen so that the quote blocks get rendered as \code{...}.

codecov[bot] commented 1 year ago

Codecov Report

Merging #39 (99b1806) into master (56b646a) will increase coverage by 0.00%. The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master      #39   +/-   ##
=======================================
  Coverage   99.49%   99.50%           
=======================================
  Files           4        4           
  Lines         395      401    +6     
=======================================
+ Hits          393      399    +6     
  Misses          2        2           
Impacted Files Coverage Δ
R/proxy.R 99.12% <100.00%> (+0.04%) :arrow_up:

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

rcannood commented 1 year ago

Sure, that makes sense!