Access Windows Registry inside R
问题 How can I access the windows registry inside R. For example, I want to access the folder: [HKEY_LOCAL_MACHINE\SOFTWARE\R-core\R\3.0.2] and the key called "InstallPath" to get: "C:\\Program Files\\R\\R-3.0.2" Many thanks! 回答1: You could use readRegistry() . On my machine: fp <- file.path("SOFTWARE", "R-core", "R", "3.1.0", fsep="\\") readRegistry(fp, "HLM") ## "HLM" eventually resolves to "HKEY_LOCAL_MACHINE" # $InstallPath # [1] "C:\\R\\R-current" (Also, for future reference, in this case you