Jargal
February 14, 2019, 7:51pm
1
Hello, I am a new R user. I am currently trying to install packages on my mac (macOS Mojave).
install.packages("class")
Warning in install.packages :
unable to access index for repository http://stat.ethz.ch/CRAN/src/contrib:
cannot open URL 'http://stat.ethz.ch/CRAN/src/contrib/PACKAGES '
package ‘class’ is not available (for R version 3.5.2)
Can anyone help me with this issue. Thanks in advance
Choose another repository, generally the closer geographically the better.
In RStudio: Tools | Global Options | Packages | CRAN mirror | Change
A list of repos is at https://cran.r-project.org/mirrors.html
In R console Preferences | Startup | Default Cran Mirror
Try with Rstudio's CRAN repository
install.packages('class', repos='http://cran.rstudio.com/')
If you still get this error message, check if your internet connection is behind a proxy server or firewall.
Jargal
February 15, 2019, 5:04pm
4
many thanks for your help. it worked.
If your question's been answered (even by you!), would you mind choosing a solution? It helps other people see which questions still need help, or find solutions if they have similar problems. Here’s how to do it:
If your question has been answered, don't forget to mark the solution!
How do I mark a solution?
Find the reply you want to mark as the solution and look for the row of small gray icons at the bottom of that reply. Click the one that looks like a box with a checkmark in it:
[image]
Hovering over the mark solution button shows the label, "Select if this reply solves the problem". If you don't see the mark solution button, try clicking the three dots button ( ••• ) to expand the full set of options.
When a solution is chosen, the icon turns green and the hover label changes to: "Unselect if this reply no longer solves the problem". Success!
[solution_reply_author]
…
1 Like
system
Closed
March 8, 2019, 5:40pm
6
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.