yuabrahamliu / CWGCNA

CWGCNA is an R package to perform causal inference from the WGCNA framework.
12 stars 2 forks source link

Error about installation #8

Closed zch0803 closed 5 months ago

zch0803 commented 5 months ago

When I installed CWGCNA according to instructions, install_github("yuabrahamliu/CWGCNA") returned a error. Error: Failed to install 'CWGCNA' from GitHub: input string 1 is invalid Warning: In gsub("\n([^[:blank:]])", "\n \\1", val) : unable to translate 'WGCNA (weighted gene co-expression network analysis) is a very useful tool for identifying co-expressed gene modules and detecting their correlations to phenotypic traits. Here, we explored more possibilities about it and developed the R packa...' to a wide string I also tried to use remotes library to install, the error occured again. My R version is 4.4.0, could you give me some help?

yuabrahamliu commented 5 months ago

It is about your UTF-8 encoding. You can run Sys.getlocale() in your R session. If it returns "Chinese", you can change it to "English_United States.utf8" with Sys.setlocale(category = "LC_ALL", locale = "English_United States.utf8"). Then install the package.

However, if it does not work, please change back to your original encoding with Sys.setlocale, because it may cause encoding problems. You can get more from the help document of Sys.setlocale.

zch0803 commented 5 months ago

It works!! Thanks very much.