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

Hello, I'm attempting to install ggplot2 but keep receiving this error after I try to load it:

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

I believe I have dependencies installed and tried to download Tidyverse as well with no success in loading the package still. Any help is appreciated

If you haven't already, you need to


before use library()

I did already. I’ve figured out the problem was elsewhere. Thanks

Make sure to download the necessary packages before you try to call them from your library. On the R Studio IDE, there are several ways to do this. One is to use the bottom right window and select the tab "Packages". From there click the option "install" and search "ggplot2". A much faster and direct way is to just use the function


For example:

install.packages("ggplot2") should be implemented before using the function library()

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.