Minor changes towards making R CMD check work

Bunch of stuff still to go (see email).

I'd really consider not exporting everything and then you can focus on documenting only the really needed stuff.