netrankr
netrankr copied to clipboard
goodpractice alerts
I ran goodpractice::gp()
, which flagged a few practices that might be changed to make code less fragile (though the quality of the code overall seems solid):
-
sapply()
can return different structures, especially whensimplify
is not set toFALSE
;vapply()
is more stable. -
F
andT
are variables that can be redefined;FALSE
andTRUE
are more stable. - The single-colon operator
:
can produce unexpected output on edge cases; theseq_*()
functions are more stable.
It also indicated that only 65% of code lines are covered by tests.
While i follow these practices myself, i leave it to the developers to decide for themselves; they will not affect my review. : )
Part of this JOSS review.