MLSeq package error - r

I would like to use MLSeq package but I am getting this error.
library(MLSeq)
Error : object ‘bag.default’ is not exported by 'namespace:caret'
Error: package or namespace load failed for ‘MLSeq’
How can I overcome this error?
sessionInfo() R version 3.3.1 (2016-06-21) Platform: x86_64-apple-darwin13.4.0 (64-bit) Running under: OS X 10.12.1 (Sierra)
Output:
locale: [1]
en_CA.UTF-8/en_CA.UTF-8/en_CA.UTF-8/C/en_CA.UTF-8/en_CA.UTF-8
attached base packages: [1] parallel stats4 stats graphics
grDevices utils datasets methods base
other attached packages: [1] edgeR_3.14.0
randomForest_4.6-12 limma_3.28.21 DESeq2_1.12.4
SummarizedExperiment_1.2.3 Biobase_2.32.0
GenomicRanges_1.24.3 [8] GenomeInfoDb_1.8.7
IRanges_2.6.1 S4Vectors_0.10.3
BiocGenerics_0.18.0 caret_6.0-72 ggplot2_2.1.0
lattice_0.20-34
loaded via a namespace (and not attached): [1] Rcpp_0.12.7
locfit_1.5-9.1 digest_0.6.10 foreach_1.4.3
plyr_1.8.4 chron_2.3-47 acepack_1.4.1
MatrixModels_0.4-1 RSQLite_1.0.0 [10] zlibbioc_1.18.0
minqa_1.2.4 data.table_1.9.6 annotate_1.50.1
SparseM_1.72 car_2.1-3 nloptr_1.0.4
rpart_4.1-10 Matrix_1.2-7.1 [19] splines_3.3.1
lme4_1.1-12 BiocParallel_1.6.6 geneplotter_1.50.0
stringr_1.1.0 foreign_0.8-67 RCurl_1.95-4.8
munsell_0.4.3 mgcv_1.8-15 [28] htmltools_0.3.5
nnet_7.3-12 gridExtra_2.2.1 htmlTable_1.7
Hmisc_4.0-0 codetools_0.2-15 XML_3.98-1.4
MASS_7.3-45 bitops_1.0-6 [37] ModelMetrics_1.1.0
grid_3.3.1 nlme_3.1-128 xtable_1.8-2
gtable_0.2.0 DBI_0.5-1 magrittr_1.5
scales_0.4.0 stringi_1.1.2 [46] XVector_0.12.1
reshape2_1.4.2 genefilter_1.54.2 latticeExtra_0.6-28
Formula_1.2-1 RColorBrewer_1.1-2 iterators_1.0.8
tools_3.3.1 pbkrtest_0.4-6 [55] survival_2.40-1
AnnotationDbi_1.34.4 colorspace_1.2-7 cluster_2.0.5
knitr_1.14 quantreg_5.29

The error arises from importing "bag.default" function in caret. NAMESPACE is fixed in the development version 1.15.1. You can download the source files from https://github.com/Bioconductor-mirror/MLSeq. With the upcoming version 1.16.0, namespace error will be fixed in the released version.

Related

ggparagraph is not displayed

I have problem with the function ggparagraph() from ggpubr package. Its content is not drawing. If I use the function:
example(ggparagraph)
The plot is drawing without any problem, but the "ggparagraph area" (below plot) is empty. The same problem is if I use custom scripts, where the ggparagraph is applied.
R does not print any error message. Where can be the problem?
My session info is:
sessionInfo()
R version 3.4.1 (2017-06-30)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 15063)
Matrix products: default
locale:
1 LC_COLLATE=Slovak_Slovakia.1250 LC_CTYPE=Slovak_Slovakia.1250
[3] LC_MONETARY=Slovak_Slovakia.1250 LC_NUMERIC=C
[5] LC_TIME=Slovak_Slovakia.1250
attached base packages:
1 stats graphics grDevices utils datasets methods base
other attached packages:
1 ggpubr_0.1.4 magrittr_1.5 gridExtra_2.2.1 dplyr_0.7.2
[5] purrr_0.2.3 readr_1.1.1 tidyr_0.6.3 tibble_1.3.3
[9] ggplot2_2.2.1 tidyverse_1.1.1
loaded via a namespace (and not attached):
1 Rcpp_0.12.12 cellranger_1.1.0 compiler_3.4.1 plyr_1.8.4
[5] bindr_0.1 forcats_0.2.0 tools_3.4.1 jsonlite_1.5
[9] lubridate_1.6.0 nlme_3.1-131 gtable_0.2.0 lattice_0.20-35
[13] pkgconfig_2.0.1 rlang_0.1.2 psych_1.7.5 parallel_3.4.1
[17] haven_1.1.0 bindrcpp_0.2 xml2_1.1.1 stringr_1.2.0
[21] httr_1.2.1 hms_0.3 cowplot_0.8.0 grid_3.4.1
[25] glue_1.1.1 R6_2.2.2 readxl_1.0.0 foreign_0.8-69
[29] reshape2_1.4.2 modelr_0.1.1 scales_0.4.1 rvest_0.3.2
[33] assertthat_0.2.0 mnormt_1.5-5 colorspace_1.3-2 labeling_0.3
[37] stringi_1.1.5 lazyeval_0.2.0 munsell_0.4.3 broom_0.4.2
Finally, I don't find where is the problem, but if I install this package from github (instead of CRAN), all paragraphs are rendered correctly.

R lapack routines cannot be loaded when using dtwclust

I am using shape method in dtwclust package. When I run the following code:
data(uciCT)
hc.sbd <- tsclust(CharTraj, type = "hierarchical",
k = 20L, distance = "sbd",
preproc = zscore, centroid = shape_extraction,
seed = 320L)
I have the following error information:
Error in eigen(M) : LAPACK routines cannot be loaded
In addition: Warning message:
In eigen(M) :
unable to load shared object '//PAPER/fchen4/R/R-3.3.2/modules/x64/lapack.dll':
`maximal number of DLLs reached...
After I use library(mgcv), I have got:
Error in eigen(M) : LAPACK routines cannot be loaded
How can I fix this error? I have tried the answers in R lapack routines cannot be loaded. But they do not work for me. I have also updated all the packages. But still cannot work.
The information from sessionInfo() is:
R version 3.3.2 (2016-10-31)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)
locale:
[1] LC_COLLATE=English_Australia.1252 LC_CTYPE=English_Australia.1252 LC_MONETARY=English_Australia.1252 LC_NUMERIC=C
[5] LC_TIME=English_Australia.1252
attached base packages:
[1] parallel splines stats graphics grDevices utils datasets methods base
other attached packages:
[1] mgcv_1.8-17 nlme_3.1-131 dtwclust_3.1.2 dtw_1.18-1 clue_0.3-53
[6] ROSE_0.0-3 scatterplot3d_0.3-39 plot3D_1.1 ggrepel_0.6.5 pdfCluster_1.0-2
[11] pastecs_1.3-18 boot_1.3-18 geosphere_1.5-5 sp_1.2-4 XLConnect_0.2-12
[16] XLConnectJars_0.2-12 ica_1.0-1 visNetwork_1.0.3 igraph_1.0.1 Barnard_1.8
[21] Kendall_2.2 pspearman_0.3-0 FSelector_0.21 dunn.test_1.3.4 randomUniformForest_1.1.5
[26] dbscan_1.1-1 Hmisc_4.0-2 Formula_1.2-1 xgboost_0.6-4 doParallel_1.0.10
[31] iterators_1.0.8 foreach_1.4.3 corrplot_0.77 gbm_2.1.3 survival_2.41-3
[36] AppliedPredictiveModeling_1.1-6 e1071_1.6-8 mlbench_2.1-1 caret_6.0-73 lattice_0.20-35
[41] fpc_2.1-10 devtools_1.12.0 lubridate_1.6.0 ggmap_2.6.1 gridExtra_2.2.1
[46] leaflet_1.1.0 qdap_2.2.5 RColorBrewer_1.1-2 qdapTools_1.3.1 qdapRegex_0.6.0
[51] qdapDictionaries_1.0.6 stringr_1.2.0 xtable_1.8-2 tidyr_0.6.1 scales_0.4.1
[56] plotly_4.5.6 ggplot2_2.2.1 psych_1.7.3.21 mxnet_0.9.4 randomForest_4.6-12
[61] cluster_2.0.6 pROC_1.9.1 openxlsx_4.0.17 proxy_0.4-17 dplyr_0.5.0
[66] plyr_1.8.4
loaded via a namespace (and not attached):
[1] backports_1.0.5 lazyeval_0.2.0 entropy_1.2.1 openNLP_0.2-6 crosstalk_1.0.0 digest_0.6.12 htmltools_0.3.5 gender_0.5.1
[9] gdata_2.17.0 magrittr_1.5 checkmate_1.8.2 memoise_1.0.0 xlsx_0.5.7 tm_0.7-1 wordcloud_2.5 jpeg_0.1-8
[17] colorspace_1.3-2 RWeka_0.4-33 RCurl_1.95-4.8 jsonlite_1.4 lme4_1.1-12 registry_0.3 gtable_0.2.0 MatrixModels_0.4-1
[25] car_2.1-4 kernlab_0.9-25 prabclus_2.2-6 DEoptimR_1.0-8 maps_3.1.1 SparseM_1.76 mvtnorm_1.0-6 rngtools_1.2.4
[33] DBI_0.6-1 Rcpp_0.12.10 CORElearn_1.50.3 plotrix_3.6-4 viridisLite_0.2.0 htmlTable_1.9 magic_1.5-6 foreign_0.8-67
[41] mapproj_1.2-4 mclust_5.2.3 stats4_3.3.2 htmlwidgets_0.8 httr_1.2.1 acepack_1.4.1 modeltools_0.2-21 XML_3.98-1.6
[49] rJava_0.9-8 flexmix_2.3-13 openNLPdata_1.5.3-2 nnet_7.3-12 venneuler_1.1-0 reshape2_1.4.2 munsell_0.4.3 tools_3.3.2
[57] geometry_0.3-6 knitr_1.15.1 ModelMetrics_1.1.0 robustbase_0.92-7 caTools_1.17.1 purrr_0.2.2 RgoogleMaps_1.4.1 mime_0.5
[65] quantreg_5.29 slam_0.1-40 compiler_3.3.2 flexclust_1.3-4 pbkrtest_0.4-7 png_0.1-7 tibble_1.3.0 stringi_1.1.5
[73] trimcluster_0.1-2 Matrix_1.2-8 nloptr_1.0.4 RWekajars_3.9.1-3 data.table_1.10.4 bitops_1.0-6 httpuv_1.3.3 R6_2.2.0
[81] latticeExtra_0.6-28 codetools_0.2-15 reports_0.1.4 MASS_7.3-45 gtools_3.5.0 assertthat_0.1 chron_2.3-50 proto_1.0.0
[89] xlsxjars_0.6.1 pkgmaker_0.22 rjson_0.2.15 withr_1.0.2 mnormt_1.5-5 diptest_0.75-7 grid_3.3.2 rpart_4.1-10
[97] class_7.3-14 minqa_1.2.4 misc3d_0.8-4 NLP_0.1-10 shiny_1.0.1 base64enc_0.1-3

Function not found, though package installed an attached

im tryring to run dcc.est from the ccgarch-package.
Even though I installed the package and attached it with library(ccgarch), I get the following error:
library(ccgarch)
dcc <- dcc.est(dvar, param)
Error: could not find function "dcc.est"
I also tried the following:
dcc <- ccgarch::dcc.est(dvar, param)
Error: object 'dcc.est' is not exported by 'namespace:ccgarch'
Accordingly to the vignette of ccgarch version 0.2.3 (https://cran.r-project.org/web/packages/ccgarch/ccgarch.pdf) , dcc.est is part of the package. What am I doing wrong?
See my sessionInfobelow:
> sessionInfo()
R version 3.3.2 (2016-10-31)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)
locale:
[1] LC_COLLATE=German_Germany.1252 LC_CTYPE=German_Germany.1252 LC_MONETARY=German_Germany.1252
[4] LC_NUMERIC=C LC_TIME=German_Germany.1252
attached base packages:
[1] parallel stats graphics grDevices utils datasets methods base
other attached packages:
[1] pracma_1.9.5 kerdiest_1.2 evir_1.7-3 chron_2.3-48 date_1.2-35
[6] fGarch_3010.82.1 fBasics_3011.87 timeSeries_3022.101.2 timeDate_3012.100 rugarch_1.3-6
[11] tsDyn_0.9-44 ccgarch_0.2.3 gdata_2.17.0 gtools_3.5.0 tidyr_0.6.0
[16] dplyr_0.5.0
loaded via a namespace (and not attached):
[1] rgl_0.96.0 Rcpp_0.12.8 mvtnorm_1.0-5 lattice_0.20-34
[5] zoo_1.7-14 assertthat_0.1 digest_0.6.10 lmtest_0.9-34
[9] foreach_1.4.3 mime_0.5 truncnorm_1.0-7 R6_2.2.0
[13] plyr_1.8.4 tseriesChaos_0.1-13 ggplot2_2.2.0 lazyeval_0.2.0
[17] misc3d_0.8-4 fracdiff_1.4-2 nloptr_1.0.4 SkewHyperbolic_0.3-2
[21] Matrix_1.2-7.1 htmlwidgets_0.8 munsell_0.4.3 shiny_0.14.2
[25] numDeriv_2016.8-1 httpuv_1.3.3 DistributionUtils_0.5-1 mnormt_1.5-5
[29] forecast_7.3 urca_1.3-0 mgcv_1.8-15 htmltools_0.3.5
[33] vars_1.5-2 nnet_7.3-12 Rsolnp_1.16 multicool_0.1-10
[37] expm_0.999-0 tibble_1.2 quadprog_1.5-5 codetools_0.2-15
[41] MASS_7.3-45 GeneralizedHyperbolic_0.8-1 grid_3.3.2 nlme_3.1-128
[45] jsonlite_1.1 xtable_1.8-2 gtable_0.2.0 DBI_0.5-1
[49] magrittr_1.5 scales_0.4.1 KernSmooth_2.23-15 tseries_0.10-36
[53] xts_0.9-7 sandwich_2.3-4 spd_2.0-1 iterators_1.0.8
[57] tools_3.3.2 ks_1.10.4 colorspace_1.3-2 knitr_1.15.1
If you look at the NAMESPACE you see that dcc.est is commented out (it may have be replaced by dcc.estimation - just a guess, I've never used the package?).
This means it is not exported by the package, but it's still there, only as an internal function. You can access internal functions by using 3 colons
ccgarch:::dcc.est
As it's in the documentation I think somewhere along the line of updates and releases someone forgot to remove it properly, or un-comment it again in the export list.

Shiny Apps Error in R Studio

My Shiny apps had been running fine until last week.
I am trying to run the apps today and getting errors in most of them :
Below is the error and my sessionInfo.
I am using Shinydashboard and other shiny libraries to render an app.
Error in withReactiveDomain(shinysession, { :
No handler registered for for type file1:shiny.file
sessionInfo()
R version 3.3.1 (2016-06-21)
Platform: x86_64-apple-darwin13.4.0 (64-bit)
Running under: OS X 10.10.1 (Yosemite)
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] parallel stats4 grid stats graphics grDevices utils datasets methods base
other attached packages:
[1] locfit_1.5-9.1 ggbiplot_0.55 scales_0.4.0
[4] chimera_1.14.0 Homo.sapiens_1.3.1 org.Hs.eg.db_3.3.0
[7] GO.db_3.3.0 OrganismDbi_1.14.1 TxDb.Hsapiens.UCSC.hg19.knownGene_3.2.2
[10] GenomicFeatures_1.24.5 BSgenome.Hsapiens.UCSC.hg19_1.4.0 BSgenome_1.40.1
[13] rtracklayer_1.32.2 AnnotationDbi_1.34.4 GenomicAlignments_1.8.4
[16] Rsamtools_1.24.0 Biostrings_2.40.2 XVector_0.12.1
[19] BiocInstaller_1.22.3 gTrack_0.1.0 gUtils_0.2.0
[22] data.table_1.9.6 stringr_1.1.0 devtools_1.12.0
[25] reshape_0.8.5 DESeq2_1.12.4 SummarizedExperiment_1.2.3
[28] Biobase_2.32.0 GenomicRanges_1.24.3 GenomeInfoDb_1.8.7
[31] IRanges_2.6.1 S4Vectors_0.10.3 BiocGenerics_0.18.0
[34] xlsx_0.5.7 xlsxjars_0.6.1 rJava_0.9-8
[37] shinydashboard_0.5.3 DT_0.2 shiny_0.14.1
[40] ggplot2_2.1.0 sva_3.20.0 genefilter_1.54.2
[43] mgcv_1.8-15 nlme_3.1-128 matrixStats_0.51.0
[46] pvclust_2.0-0 gplots_3.0.1 reshape2_1.4.1
[49] plyr_1.8.4 ComplexHeatmap_1.11.7
loaded via a namespace (and not attached):
[1] colorspace_1.2-7 rjson_0.2.15 class_7.3-14 modeltools_0.2-21 mclust_5.2
[6] circlize_0.3.9 GlobalOptions_0.0.10 flexmix_2.3-13 mvtnorm_1.0-5 splines_3.3.1
[11] robustbase_0.92-6 geneplotter_1.50.0 Formula_1.2-1 jsonlite_1.1 annotate_1.50.1
[16] cluster_2.0.5 kernlab_0.9-25 graph_1.50.0 httr_1.2.1 Matrix_1.2-7.1
[21] acepack_1.3-3.3 htmltools_0.3.5 tools_3.3.1 gtable_0.2.0 Rcpp_0.12.7
[26] trimcluster_0.1-2 gdata_2.17.0 fpc_2.1-10 mime_0.5 gtools_3.5.0
[31] XML_3.98-1.4 dendextend_1.3.0 DEoptimR_1.0-6 zlibbioc_1.18.0 MASS_7.3-45
[36] RBGL_1.48.1 RColorBrewer_1.1-2 yaml_2.1.13 curl_2.1 memoise_1.0.0
[41] gridExtra_2.2.1 biomaRt_2.28.0 rpart_4.1-10 latticeExtra_0.6-28 stringi_1.1.2
[46] RSQLite_1.0.0 caTools_1.17.1 BiocParallel_1.6.6 shape_1.4.2 chron_2.3-47
[51] prabclus_2.2-6 bitops_1.0-6 lattice_0.20-34 htmlwidgets_0.7 labeling_0.3
[56] magrittr_1.5 R6_2.2.0 Hmisc_3.17-4 DBI_0.5-1 whisker_0.3-2
[61] foreign_0.8-67 withr_1.0.2 survival_2.39-5 RCurl_1.95-4.8 nnet_7.3-12
[66] KernSmooth_2.23-15 GetoptLong_0.1.5 git2r_0.15.0 digest_0.6.10 diptest_0.75-7
[71] xtable_1.8-2 httpuv_1.3.3 munsell_0.4.3
Any idea,what this could be?
Thanks,
Ron
Shiny version 0.14.2 was published last week (along with new versions of R and RStudio). Maybe this broke something in your code. One way to protect against this is to use something like packrat package that locks in a certain version of an R package so that your code is not changed by a new package. You can then test your code against an upgrade and troubleshoot before using that new version.
Restarting R studio worked.There was no need to update any packages.

GSEA-R error R Mac OSX El Capitan

Not sure how many people still use the R script for GSEA, but when I try and load the script and its functions:
GSEA.program.location <- ("file location of GSEA.1.0.R")
source(GSEA.program.location, verbose=T, max.deparse.length=9999)
I get this error
'envir' chosen:<environment: R_GlobalEnv>
encoding = "native.enc" chosen
Error: '\%' is an unrecognized escape in character string starting ""Tag \%"
I believe I have to remove the backspace, but I have searched through GSEA.1.0.R, and the "source" function source code, and I can't find this '\%'. What is it that I am doing wrong?
Session info:
R version 3.2.2 (2015-08-14)
Platform: x86_64-apple-darwin13.4.0 (64-bit)
Running under: OS X 10.11.1 (El Capitan)
locale:
[1] C/C/C/C/C/en_GB.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] biomaRt_2.26.0 WGCNA_1.48 RSQLite_1.0.0 DBI_0.3.1 fastcluster_1.1.16 dynamicTreeCut_1.62
loaded via a namespace (and not attached):
[1] reshape2_1.4.1 splines_3.2.2 lattice_0.20-33 colorspace_1.2-6 htmltools_0.2.6
[6] stats4_3.2.2 yaml_2.1.13 survival_2.38-3 XML_3.98-1.3 foreign_0.8-66
[11] BiocGenerics_0.16.1 RColorBrewer_1.1-2 matrixStats_0.15.0 foreach_1.4.3 plyr_1.8.3
[16] stringr_1.0.0 munsell_0.4.2 gtable_0.1.2 codetools_0.2-14 latticeExtra_0.6-26
[21] Biobase_2.30.0 IRanges_2.4.1 doParallel_1.0.10 parallel_3.2.2 AnnotationDbi_1.32.0
[26] preprocessCore_1.32.0 GSEABase_1.32.0 proto_0.3-10 Rcpp_0.12.1 acepack_1.3-3.3
[31] xtable_1.8-0 scales_0.3.0 S4Vectors_0.8.1 Hmisc_3.17-0 graph_1.48.0
[36] annotate_1.48.0 gridExtra_2.0.0 impute_1.44.0 ggplot2_1.0.1 digest_0.6.8
[41] stringi_1.0-1 grid_3.2.2 tools_3.2.2 bitops_1.0-6 magrittr_1.5
[46] RCurl_1.95-4.7 Formula_1.2-1 cluster_2.0.3 GO.db_3.2.2 MASS_7.3-45
[51] rmarkdown_0.8.1 iterators_1.0.8 rpart_4.1-10 nnet_7.3-11
These warnings occur when you have R version 2.5 and higher installed. To fix, remove the single backslashes in front of these characters as there is no need to escape them in R versions 2.5 and higher.

Resources