I'm running R (version 4.2.3 (2023-03-15) -- "Shortstop Beagle") and RStudio (Version 2023.03.0+386 (2023.03.0+386)) and have some problems reading files with unicode characters. I have not had this issue before, and opening the .R or .Rmd files in native R works well (see attached screenshots). I'm on macOS Monetery (12.5.1).
I've tried saving with encoding UTF-8 but it doesn't help. Any advice on what to do? I feel there are many similar issues and solutions out there but some are outdated and many seen Windows-specific. Thanks so much in advance!
Hi, sorry I should have been more clear. The script used to look like the white part of the screenshot. I.e., to read and rename a csv file with unicode characters, I would use unicode characters in the script. Nowadays when I open the script in RStudio (but not base R), the unicode characters are changed. And therefore I can't run the script before I replace all weird characters with the unicode ones. Then I can run the script, but next time I open it I have to redo that step.
Alright, this is solved now! An hour ago I was asked to update to version 2023.03.1+446 (2023.03.1+446) and the problem dissapeared. I can now open .R and .Rmd files with unicode characters and they are displayed correctly in RStudio.