Re: [R] Installed packages: Bioconductor vs CRAN?

2021-09-24 Thread Leonard Mada via R-help
[working version] On 9/25/2021 2:55 AM, Leonard Mada wrote: Dear List Members, Is there a way to extract if an installed package is from Bioconductor or if it is a regular Cran package? The information seems to be *not* available in: installed.packages() ### [updated] # Basic Info: inf

Re: [R] Installed packages: Bioconductor vs CRAN?

2021-09-24 Thread Leonard Mada via R-help
Dear Bert, Indeed, this seems to work: installed.packages(fields="Repository") I still need to figure out what variants to expect. Sincerely, Leonard On 9/25/2021 3:31 AM, Leonard Mada wrote: Dear Bert, The DESCRIPTION file contains additional useful information, e.g.: 1.) Package E

Re: [R] Installed packages: Bioconductor vs CRAN?

2021-09-24 Thread Leonard Mada via R-help
Dear Bert, The DESCRIPTION file contains additional useful information, e.g.: 1.) Package EBImage: biocViews: Visualization Packaged: 2021-05-19 23:53:29 UTC; biocbuild 2.) deSolve Repository: CRAN I have verified a few of the CRAN packages, and they seem to include the tag: Repository:

Re: [R] Installed packages: Bioconductor vs CRAN?

2021-09-24 Thread Bert Gunter
Oh, I should have added that packages can be on other repositories (local, github,...) and I think can be both in CRAN and BIOC . So your query would not seem to have a clear answer. AFAICS anyway. Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking thi

Re: [R] Installed packages: Bioconductor vs CRAN?

2021-09-24 Thread Bert Gunter
The help file tells you that installed.packages() looks at the DESCRIPTION files of packages. Section 1.1.1 of "Writing R Extensions" tells you what information is in such files. Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- O

[R] Installed packages: Bioconductor vs CRAN?

2021-09-24 Thread Leonard Mada via R-help
Dear List Members, Is there a way to extract if an installed package is from Bioconductor or if it is a regular Cran package? The information seems to be *not* available in: installed.packages() Sincerely, Leonard === I started to write some utility functions to analyse installed

Re: [R] alternative to subset(dataframe, select = - column) in R

2021-09-24 Thread Bert Gunter
If you correct my typo as my followup message indicated, match() works fine. As does logical indexing with %in%. The != version will work for your query, but does not generalize to deleting several columns. The point is to heed Jeff N's advice. Bert Gunter "The trouble with having an open mind i

Re: [R] Unusual Error Loading tidyverse

2021-09-24 Thread Kevin Thorpe
Ah. Thanks Duncan. That makes sense based on some other messages I caught a glimpse of as we tried some things. I will investigate down this line. > On Sep 24, 2021, at 3:26 PM, Duncan Murdoch wrote: > > It is worth checking that the library where things were most recently > installed is the

Re: [R] alternative to subset(dataframe, select = - column) in R

2021-09-24 Thread Luigi Marongiu
Thank you! ``` new_out <- new[ , "ID" != names( new ) ] new[names(new) != "ID"] ``` worked as wanted, `new[-match("ID"), names(new)]` gave the error: `Error in match("ID") : argument "table" is missing, with no default`. Cheers On Fri, Sep 24, 2021 at 7:33 PM Rui Barradas wrote: > > Hello, > > Li

Re: [R] Unusual Error Loading tidyverse

2021-09-24 Thread Duncan Murdoch
It is worth checking that the library where things were most recently installed is the first place R looks, i.e. the first entry in .libPaths(). Often R is installed by an administrator, and users can't write to the main library, so when they install packages they go somewhere else. If "somew

Re: [R] Unusual Error Loading tidyverse

2021-09-24 Thread Kevin Thorpe
I did try installing xml2 and it appeared to complete. I will ask him to try again and send me the output. > On Sep 24, 2021, at 1:58 PM, Jeff Newmiller wrote: > > Seems like they should install the xml2 package before proceeding to load > whatever (tidyverse). > > This kind of "dependency m

Re: [R] Unusual Error Loading tidyverse

2021-09-24 Thread Jeff Newmiller
Seems like they should install the xml2 package before proceeding to load whatever (tidyverse). This kind of "dependency missing" problem tends to be a recurring problem particularly on Windows but in general when some deeply-embedded dependency fails to load or is removed in preparation for up

[R] Unusual Error Loading tidyverse

2021-09-24 Thread Kevin Thorpe
Below is some output from one of my students. I have never seen this error and tried a few things (updating packages for one) but am at a loss to help further. Would appreciate suggestions that I can pass along. Here is the error. I tried an install.packages(“xml2”) which appeared to complete b

Re: [R] alternative to subset(dataframe, select = - column) in R

2021-09-24 Thread Rui Barradas
Hello, Like this? mtcars[names(mtcars) != "mpg"] Hope this helps, Rui Barradas Às 15:09 de 24/09/21, Luigi Marongiu escreveu: Hello, this is a very simple question but... what is the vector alternative to `subset(dataframe, select = - column)`? I tried with: ``` x = new[-ID] Error in `[.

Re: [R] alternative to subset(dataframe, select = - column) in R

2021-09-24 Thread Bert Gunter
typo. Correction: x <- new[-match("ID", names(new))] Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Fri, Sep 24, 2021 at 7:31 AM Bert Gunter wrote: > > x <- n

Re: [R] alternative to subset(dataframe, select = - column) in R

2021-09-24 Thread Jeff Newmiller
The subset function subset( new, select = -ID ) uses non-standard evaluation... it "knows" that when you write the language symbol ID it may match to one of the column names in new, and the `-` in the select argument will be noticed before R tries to change the sign of a variable ID in your ca

Re: [R] alternative to subset(dataframe, select = - column) in R

2021-09-24 Thread Bert Gunter
x <- new[-match("ID"), names(new))] Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Fri, Sep 24, 2021 at 7:10 AM Luigi Marongiu wrote: > > Hello, > this is a ve

[R] alternative to subset(dataframe, select = - column) in R

2021-09-24 Thread Luigi Marongiu
Hello, this is a very simple question but... what is the vector alternative to `subset(dataframe, select = - column)`? I tried with: ``` > x = new[-ID] Error in `[.data.frame`(new, -ID) : object 'ID' not found > x = new[-"ID"] Error in -"ID" : invalid argument to unary operator > x = new[[-"ID"]] E