Issue #20
resolved
Have you tried adding
ByteCompile: true
to the DESCRIPTION file? In my poweRlaw package, this give a four times speed-up.
I hear there's an excellent book on efficient R programming you can consult ;)
Comments (2)
-
repo owner -
repo owner - changed status to resolved
using this in assertive.* pkgs instead
- Log in to comment
Nice tip.
It doesn't work for assertive, since that package now doesn't contain any of its own content. I've had a play with using byte compilation in assertive.base. For most of the simpler functions, there's no performance difference, but a few like
is2
showed around ~20% speedup. Which is worth it for 1 extra line of code.