DEGreport icon indicating copy to clipboard operation
DEGreport copied to clipboard

Error in DEGpatterns: could not find function "set"

Open gowgowuk opened this issue 1 year ago • 11 comments

Hello,

First of all bear with me as I'm not very proficient in R... I used an older version of DEGpatterns (DEGreport_1.30.3 running on R version 4.1.2). However, I wanted the option to choose the number of clusters (nClusters=) not available on this version. I decided then to update both R (to R 4.3-arm64) and DEGreport_1.39_3. I am on a Mac M1 and running this in Rstudio. Unfortunately, the script now fails as I have the following error message: dp<-degPatterns(vst_data,time="time",metadata = colData(dds_time), nClusters=5) Error in set(., "labels", "") : could not find function "set" The clusters appears fine as plots, but the object (dp) is not saved. Could you possibly tell me if I'm doing something wrong? Looking at the function, it seems that one of the "set" command is "dendextend::set", but second is just "set" (and that's the problematic one , as far as I understand the script.

Many thanks,

Regards, Philippe

gowgowuk avatar Dec 06 '23 15:12 gowgowuk

Hi Philippe, you have asessed the problem absoulutely correct. As a workaround solution, try to source the clustering.R file and load the library(dendextend) manually. And probably you will also need library(tibble) and library(tidyr). Bug will be fixed soon, thanks for pointing it out

zellerivo avatar Dec 12 '23 17:12 zellerivo

Hello again,

I've tried to install the latest version you mentioned as temporary fix in issue #62 (avoid using dendextend). However, I have now another error: Error in degPatterns(vst_data, time = "time", metadata = colData(dds_time), : object 'skipDendrogram' not found

The version of the package I am using is now: DEGreport_1.39.4

Thanks

Philippe

gowgowuk avatar Jan 29 '24 15:01 gowgowuk

Hi, can you type in the console degPatterns and see if in the code you see, you can spot the parameter name? I am fixing the documentation in case that is the problem, but want to make sure the code has the right parameter name.

lpantano avatar Feb 26 '24 22:02 lpantano

Can you install again from the main branch, there was a typo. thanks

lpantano avatar Feb 26 '24 22:02 lpantano

Hello, it seems to work now. Thanks!

gowgowuk avatar Feb 28 '24 11:02 gowgowuk

Hi, has this issue been fixed already? I just got the same error. Thanks

> clusters_ntdC_all <- degPatterns(mat[1:100,], design, time="treatment",col="genotype", nClusters = 10)
Working with 100 genes.
Working with 54 genes after filtering: minc > 15
Joining with `by = join_by(merge)`
Joining with `by = join_by(merge)`
Error in set(., "labels", "") : could not find function "set"

> sessionInfo()
R version 4.3.0 (2023-04-21)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 22.04.2 LTS

Matrix products: default
BLAS:   /usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3 
LAPACK: /usr/lib/x86_64-linux-gnu/openblas-pthread/libopenblasp-r0.3.20.so;  LAPACK version 3.10.0

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C               LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8     LC_MONETARY=en_US.UTF-8   
 [6] LC_MESSAGES=en_US.UTF-8    LC_PAPER=en_US.UTF-8       LC_NAME=C                  LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

time zone: Etc/UTC
tzcode source: system (glibc)

attached base packages:
[1] stats4    stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] DEGreport_1.39.4            DESeq2_1.42.0               SummarizedExperiment_1.32.0 Biobase_2.62.0              MatrixGenerics_1.14.0      
 [6] matrixStats_1.2.0           GenomicRanges_1.54.1        GenomeInfoDb_1.38.6         IRanges_2.36.0              S4Vectors_0.40.2           
[11] BiocGenerics_0.48.1         biomaRt_2.58.2             

GrothmLab avatar Feb 29 '24 15:02 GrothmLab

hi @GrothmLab , can you try to install the version from main branch?

lpantano avatar Feb 29 '24 16:02 lpantano

Now it works! Thanks!!

GrothmLab avatar Feb 29 '24 17:02 GrothmLab

hi @GrothmLab , can you try to install the version from main branch?

Could you please elaborate on how "install the version from main branch"? I've tried

devtools::install_git("https://[email protected]/packages/DEGreport")

and got the following error:

Error: Failed to install 'unknown package' from Git:
  Command failed (1)
In addition: Warning messages:
1: In system(full, intern = TRUE, ignore.stderr = quiet) :
  running command ''/usr/bin/git' ls-remote https://[email protected]/packages/DEGreport  2>/dev/null' had status 1
2: In system(full, intern = TRUE, ignore.stderr = quiet) :
  running command ''/usr/bin/git' ls-remote https://[email protected]/packages/DEGreport  2>/dev/null' had status 1

Thank you very much!

danielsilvasilva avatar Mar 21 '24 14:03 danielsilvasilva

I think I got it to work using:

devtools::install_github("lpantano/DEGreport")

gowgowuk avatar Mar 21 '24 16:03 gowgowuk

I think I got it to work using:

devtools::install_github("lpantano/DEGreport")

Thank you. It worked!

danielsilvasilva avatar Mar 29 '24 16:03 danielsilvasilva