Error in nchar(homeDir)

Hello,I've been trying to install:

  • install.packages("spocc")
  • install.packages("rgbif")
    But some errors have appeared. First this one:
    Warning message:
    In normalizePath(path.expand(path), winslash, mustWork) : path[1]="C:/Users/Lore/OneDrive - Universidad Tecnol�gica de Pereira/Documents": El sistema no puede encontrar la ruta especificada
    I get that this error is caused by Onedrive, so I change the Working Directory, but it keeps turning to the One Drive path.

the second error is this: Error in nchar(homeDir) : invalid multibyte string, element 1

I really dont know what to do, if you could help me I would appreciate that.

Please, have in mind that I'm spanish speaker, and I'm new un R lenguaje an RStudio, Thanks

R has known issues with cloud-synced folders and non-ASCII characters in your Windows user name, the easiest solution would be to change to a new Windows account that doesn't contain any non ASCII characters on its name.

If that is not possible, start by setting your default package library in a different location (the system level package library is a good option). You can change the default library folder by setting your R_LIBS_SITE environmental variable in a .Reviron or .Rprofile file. For example:

# In a .Renviron file you can set it by adding a line like this one with the desired location 
R_LIBS_SITE="C:\\Program Files\\R\\R-4.2.1\\library"

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

Then, try to install any of those packages again and post the complete console output you get, and we can go from there.

Note: The blog post I linked is also available in Spanish, just change the language on the top right corner.

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.