install.packages ("httr") Issues

Hello Everyone,

I'm relatively new to coding and to this site so I apologize for the screenshots below. I've been trying to install various packages but keep getting error messages and warnings. Below is my code and error messages:

I also get the following error messages:

Error in library(httr) : there is no package called ‘httr’

Error in reprex() : could not find function "reprex"

Again, I apologize for the screenshot. Since install.packages() is not working it looks like I can't install reprex to provide the proper formatting. Has anyone else run into a similar issue? Thank you for the help!

This seems like a connectivity issue, R is not being able to connect to the CRAN repository you have selected, these are some things to try.

  • Choose a different CRAN repository, RStudios repository is a good choice ( or you could choose one that is geographically closer to you.
  • Disable secure download setting.
  • Check if your internet connection has traffic restrictions of some kind, like a firewall, proxy server, etc. This is usually the case when you are at work or school.

BTW, you don't need the reprex package to post formatted code here, read this post to learn how to do it.

1 Like

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.