Repository navigation
load() Error: cannot open the the connection, cannot open compressed file #1042
|
Hello, I'm very new to R, VSCode, and GitHub, so please excuse any blunders related to jargon and/or protocols regarding posting discussion—I am currently learning R, C, and Python, have been using R Studio for R and VSCode for Python and C, but I prefer VSCode, so I downloaded the vscode-R extension and installed langugaeserver in R. However, I'm trying to load data from an .Rdata file which is in the same directory as the .Rmd file I'm working on, but when I run the chunk Error in readChar(con, 5L, useBytes = TRUE) : cannot open the connection Can anyone please me, for I am confused and am able to assign variables and save them in the Global Environment, and the file is definitely not 'compressed' as the error message implies (it came in a .zip file that was uncompressed)? It would be greatly appreciated. Thank you kindly. Using must recent version of R, VSCode, R extension (by Yukki Ueda), language server, and win 11. |
Replies: 1 comment 2 replies
|
I'm no expert, but I think this is due to working directory issues? Are you opening the project folder (that encloses both files) in VS Code? Then it should work I think. But if your R file (and data file) is nested deeper in a folder and accessed by the explorer, then I'm pretty sure you need to add the path from the project folder you opened to your load or use |
I'm no expert, but I think this is due to working directory issues? Are you opening the project folder (that encloses both files) in VS Code? Then it should work I think. But if your R file (and data file) is nested deeper in a folder and accessed by the explorer, then I'm pretty sure you need to add the path from the project folder you opened to your load or use
hereor something like that.