Error in install.packages : unable to translate 'C:\Users\xghosn\OneDrive - G<U+FFFD>teborgs Universitet\Dokument\R\win-library\4.0' to native encoding

I cannot install any packages ! kindly help
I receive this message
Error in install.packages : unable to translate 'C:\Users\xghosn\OneDrive - G<U+FFFD>teborgs Universitet\Dokument\R\win-library\4.0' to native encoding

R has problems with synced folders (OneDrive) and non-ASCII facts) characters in the package library path, I recommend you to set your user-level package library on a different location, or get the system level package library instead.

You can change the default library folder by setting your R_LIBS_SITE environmental variable on a .Reviron or .Rprofile file

# In a .Renviron file you can set it by adding this line
R_LIBS_SITE="C:\\Program Files\\R\\R-4.0.3\\library"

For a more detailed explanation, you can read this blog post

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.