fixed some (but not all) R CMD CHECK problems