This display appears when you save a file or write a code.What should I do?
In Windows, R is 3.3.4.RStudio is the running environment!
r
Are you trying to save the file by opening it in another text editor, or by modifying a file that you do not have write permission to?
RStudio on Windows will cause garbled characters, but I was able to send the same error message when I tried to save the open file in RStudio in another text editor.
Are there any files or folders with the following names in the folder where the R script you are working on is located?
*Display hidden files and folders must be enabled in Windows settings.
If you're not sure, you'll be prompted by R
dir(all.files=TRUE)
Type and paste the results here (remove any statements that may contain personal information or confidentiality).
If you have these, exit RStudio and move the above two files and folders to a different location, such as your desktop.Then, if you reopen the R script in RStudio, you may not get any error messages.
You said it wasn't opened in another text editor, but isn't the working directory set to synchronize locally with online storage such as Google drives?
In my environment, I used the folder synchronized with my Google drive as the working directory, and when I was writing .Rmd and .R, similar errors occurred, and when I stopped synchronizing, I stopped getting errors.
It may depend on the specifications of the online storage, but I think the error may occur when the online storage client is browsing the file for synchronization (and often because there are minor changes to the temporary file).
© 2024 OneMinuteCode. All rights reserved.