Update R version
tidymicrobiome
require R version > 4.1.
You can check your R version in your console:
version
## _
## platform x86_64-apple-darwin20
## arch x86_64
## os darwin20
## system x86_64, darwin20
## status
## major 4
## minor 3.0
## year 2023
## month 04
## day 21
## svn rev 84292
## language R
## version.string R version 4.3.0 (2023-04-21)
## nickname Already Tomorrow
If your R version is < 4.1, please download and install the latest version of R, and then restart your R.
Install tidymicrobiome
Copy and paste the below code in your console.
if(!require(remotes)){
install.packages("remotes")
}
remotes::install_github("tidymicrobiome/tidymicrobiome", dependencies = TRUE)
Some issues
-
During the installation, it will ask if you want to update some packages for few times, just enter
Enter
orReurn
key to skip it. -
If there is a error like below:
Error: Failed to install ’tidymass’ from GitHub: HTTP error 403. API rate limit exceeded for 171.66.10.237. (But here’s the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)
Try to resolve it by:
- In you R console, type this code:
if(!require(usethis)){
install.packages("usethis")
}
usethis::create_github_token()
It will open a page in browser, and create a “New personal access token” and copy it.
- Then type this code:
usethis::edit_r_environ()
and then add one line like below:
GITHUB_PAT=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
The GITHUB_PAT should be yours that is created in step 1.
And then restart R session and try again.