champ.SVD() error, assumes standard class() function will return single string
0
0
Entering edit mode
@8df9ba1f
Last seen 12 days ago
Ireland

Enter the body of text here

Code should be placed in three backticks as shown below

I get the following error when running champ.SVD()

Error in if (class(beta) == "data.frame") { : │~ the condition has length > 1

and it cannot proceed. So beta's class is often a "matrix" "array" which is two strings, so the error seems report is evident. A check on the length of what class() returns would solve this. Seems to be a bit of an oversight.

r$> sessionInfo() R version 4.2.0 (2022-04-22) Platform: x86_64-pc-linux-gnu (64-bit) Running under: Debian GNU/Linux bookworm/sid Matrix products: default BLAS/LAPACK: /usr/lib/x86_64-linux-gnu/openblas-pthread/libopenblasp-r0.3.20.so locale: [1] LC_CTYPE=en_IE.UTF-8 LC_NUMERIC=C LC_TIME=en_IE.UTF-8 LC_COLLATE=en_IE.UTF-8 [5] LC_MONETARY=en_IE.UTF-8 LC_MESSAGES=en_IE.UTF-8 LC_PAPER=en_IE.UTF-8 LC_NAME=C [9] LC_ADDRESS=C LC_TELEPHONE=C LC_MEASUREMENT=en_IE.UTF-8 LC_IDENTIFICATION=C attached base packages: [1] parallel stats4 stats graphics grDevices utils datasets methods base other attached packages: [1] Cairo_1.5-15 gplots_3.1.3 pathfindR_1.6.3 [4] pathfindR.data_1.1.2 dplyr_1.0.9 reshape_0.8.9 [7] enrichplot_1.16.1 clusterProfiler_4.4.1 EnhancedVolcano_1.14.0 [10] ggrepel_0.9.1 ggplot2_3.3.6 limma_3.52.1 [13] sva_3.44.0 BiocParallel_1.30.2 genefilter_1.78.0 [16] mgcv_1.8-40 nlme_3.1-157 RColorBrewer_1.1-3 [19] ChAMP_2.26.0 RPMM_1.25 cluster_2.1.3 [22] DT_0.23 IlluminaHumanMethylationEPICmanifest_0.3.0 Illumina450ProbeVariants.db_1.32.0 [25] DMRcate_2.10.0 ChAMPdata_2.28.0 minfi_1.42.0 [28] bumphunter_1.38.0 locfit_1.5-9.5 iterators_1.0.14 [31] foreach_1.5.2 Biostrings_2.64.0 XVector_0.36.0 [34] SummarizedExperiment_1.26.1 Biobase_2.56.0 MatrixGenerics_1.8.0 [37] matrixStats_0.62.0 GenomicRanges_1.48.0 GenomeInfoDb_1.32.2 [40] IRanges_2.30.0 S4Vectors_0.34.0 BiocGenerics_0.42.0 loaded via a namespace (and not attached): [1] Hmisc_4.7-0 Rsamtools_2.12.0 [3] crayon_1.5.1 MASS_7.3-57 [5] rhdf5filters_1.8.0 backports_1.4.1 [7] impute_1.70.0 GOSemSim_2.22.0 [9] rlang_1.0.2 DSS_2.44.0 [11] filelock_1.0.2 rjson_0.2.21 [13] globaltest_5.50.0 bit64_4.0.5 [15] glue_1.6.2 isva_1.9 [17] rngtools_1.5.2 methylumi_2.42.0 [19] AnnotationDbi_1.58.0 DOSE_3.22.0 [21] tidyselect_1.1.2 XML_3.99-0.9 [23] nleqslv_3.3.2 tidyr_1.2.0 [25] GenomicAlignments_1.32.0 xtable_1.8-4 [27] magrittr_2.0.3 evaluate_0.15 [29] cli_3.3.0 zlibbioc_1.42.0 [31] rstudioapi_0.13 doRNG_1.8.2 [33] rpart_4.1.16 fastmatch_1.1-3 [35] ensembldb_2.20.1 treeio_1.20.0 [37] IlluminaHumanMethylationEPICanno.ilm10b4.hg19_0.6.0 shiny_1.7.1 [39] xfun_0.31 askpass_1.1 [41] clue_0.3-60 multtest_2.52.0 [43] caTools_1.18.2 tidygraph_1.2.1 [45] KEGGREST_1.36.0 tibble_3.1.7 [47] interactiveDisplayBase_1.34.0 base64_2.0 [49] ape_5.6-2 biovizBase_1.44.0 [51] scrime_1.3.5 dendextend_1.15.2 [53] png_0.1-7 permute_0.9-7 [55] withr_2.5.0 lumi_2.48.0 [57] bitops_1.0-7 ggforce_0.3.3 [59] plyr_1.8.7 AnnotationFilter_1.20.0 [61] JADE_2.0-3 pillar_1.7.0 [63] cachem_1.0.6 GenomicFeatures_1.48.1 [65] DelayedMatrixStats_1.18.0 vctrs_0.4.1 [67] ellipsis_0.3.2 generics_0.1.2 [69] tools_4.2.0 foreign_0.8-82 [71] munsell_0.5.0 tweenr_1.0.2 [73] fgsea_1.22.0 DelayedArray_0.22.0 [75] fastmap_1.1.0 compiler_4.2.0 [77] httpuv_1.6.5 rtracklayer_1.56.0 [79] geneLenDataBase_1.32.0 ExperimentHub_2.4.0 [81] beanplot_1.3.1 Gviz_1.40.1 [83] plotly_4.10.0 GenomeInfoDbData_1.2.8 [85] gridExtra_2.3 DNAcopy_1.70.0 [87] edgeR_3.38.1 lattice_0.20-45 [89] utf8_1.2.2 later_1.3.0 [91] BiocFileCache_2.4.0 jsonlite_1.8.0 [93] affy_1.74.0 scales_1.2.0 [95] tidytree_0.3.9 sparseMatrixStats_1.8.0 [97] lazyeval_0.2.2 promises_1.2.0.1 [99] doParallel_1.0.17 latticeExtra_0.6-29 [101] R.utils_2.11.0 goseq_1.48.0 [103] checkmate_2.1.0 rmarkdown_2.14 [105] nor1mix_1.3-0 statmod_1.4.36 [107] siggenes_1.70.0 dichromat_2.0-0.1 [109] downloader_0.4 BSgenome_1.64.0 [111] igraph_1.3.1 HDF5Array_1.24.0 [113] bsseq_1.32.0 survival_3.3-1 [115] yaml_2.3.5 htmltools_0.5.2 [117] memoise_2.0.1 VariantAnnotation_1.42.1 [119] BiocIO_1.6.0 graphlayouts_0.8.0 [121] quadprog_1.5-8 viridisLite_0.4.0 [123] digest_0.6.29 assertthat_0.2.1 [125] mime_0.12 rappdirs_0.3.3 [127] BiasedUrn_1.07 RSQLite_2.2.14 [129] yulab.utils_0.0.4 data.table_1.14.2 [131] blob_1.2.3 R.oo_1.24.0 [133] preprocessCore_1.58.0 fastICA_1.2-3 [135] shinythemes_1.2.0 splines_4.2.0 [137] Formula_1.2-4 Rhdf5lib_1.18.2 [139] illuminaio_0.38.0 AnnotationHub_3.4.0 [141] ProtGenerics_1.28.0 RCurl_1.98-1.6 [143] hms_1.1.1 rhdf5_2.40.0 [145] colorspace_2.0-3 base64enc_0.1-3 [147] BiocManager_1.30.17 aplot_0.1.4 [149] nnet_7.3-17 GEOquery_2.64.2 [151] Rcpp_1.0.8.3 mclust_5.4.9 [153] fansi_1.0.3 tzdb_0.3.0 [155] R6_2.5.1 grid_4.2.0 [157] lifecycle_1.0.1 curl_4.3.2 [159] kpmt_0.1.0 affyio_1.66.0 [161] DO.db_2.9 Matrix_1.4-1 [163] qvalue_2.28.0 ROC_1.72.0 [165] org.Hs.eg.db_3.15.0 stringr_1.4.0 [167] IlluminaHumanMethylation450kmanifest_0.4.0 htmlwidgets_1.5.4 [169] polyclip_1.10-0 biomaRt_2.52.0 [171] purrr_0.3.4 missMethyl_1.30.0 [173] shadowtext_0.1.2 gridGraphics_0.5-1 [175] marray_1.74.0 openssl_2.0.1 [177] htmlTable_2.4.0 patchwork_1.1.1 [179] codetools_0.2-18 IlluminaHumanMethylation450kanno.ilmn12.hg19_0.6.1 [181] GO.db_3.15.0 gtools_3.9.2 [183] prettyunits_1.1.1 dbplyr_2.1.1 [185] R.methodsS3_1.8.1 gtable_0.3.0 [187] DBI_1.1.2 wateRmelon_2.2.0 [189] ggfun_0.0.6 httr_1.4.3 [191] KernSmooth_2.23-20 stringi_1.7.6 [193] progress_1.2.2 reshape2_1.4.4 [195] farver_2.1.0 annotate_1.74.0 [197] viridis_0.6.2 ggtree_3.4.0 [199] xml2_1.3.3 combinat_0.0-8 [201] restfulr_0.0.13 readr_2.1.2 [203] ggplotify_0.1.0 BiocVersion_3.15.2 [205] bit_4.0.4 scatterpie_0.1.7 [207] jpeg_0.1-9 ggraph_2.0.5 [209] pkgconfig_2.0.3 knitr_1.39 r$>

ChAMP • 85 views
0
Entering edit mode

What is class(yourbeta) ?