R: fix more renaming bugs