I am having trouble installing packages

Error Information:

(as ‘lib’ is unspecified)
Description of issue -
I have been trying to install tidyverse but keep getting this response. Is there a way to fix this?
Steps taken so far -
I have been looking at how to run R as an administrator but I don't know-how.

System Information:

  • RStudio Edition: (Desktop or Server) Mac Os
  • RStudio Version:
  • OS Version: 10.13
  • R Version:

can you post the full output of install.packages("tidyverse")?

Here is the full output:

Installing package into ‘/Users/Tim/Library/R/4.0/library’
(as ‘lib’ is unspecified)
trying URL 'http://cran.rstudio.com/bin/macosx/contrib/4.0/tidyverse_1.3.0.tgz'
Content type 'application/x-gzip' length 433049 bytes (422 KB)
downloaded 422 KB

The downloaded binary packages are in

I will install the package then use the library function, but when I actually try to use the packages nothing happens. I know it has something to do with "(as ‘lib’ is unspecified)" because I have never seen it until today

The message containing "as lib is unspecified" is normal. If you run the command


you should see that /Users/Tim/Library/R/4.0/library is the first path listed. When you say that nothing happens when you try to use the packages, is it literally nothing? Is there no error message when you run, say

1 Like

Yes if I run library(dplyr) there is no error message. And then I’ll try to run a select() or mutate() function and won’t get a response either

What happens with this code?

DF <- data.frame(A = LETTERS[1:4], B = 1:4, C = 2:5)
DF <- select(DF,A,C)

You should see

  A C
1 A 2
2 B 3
3 C 4
4 D 5

That works- But for example, if I run this with the pipe operator:
cb<- csvframe %>%
select(team 1, team 2) %>%

I get no response, It's like I am unable to use the pipe operator and dplyr

The problems I see are that you cannot have spaces in column names without quoting them and the second pipe leads nowhere. Try

cb <- csvframe %>%
    select(`team 1`, `team 2`) 

I recommend you rename your columns to something like team_1 and team_2 so you do not have to worry about quoting the names.

1 Like

Thanks a lot, I appreciate the help!

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.