GO.db - Get newest Gene Ontology annotations - r

I am using the GO.db package in R (v3.3.2) to access information about the Gene Ontology. I can see by running the GO.db command that my annotations are outdated. (I know there are a newer set of annotations released in 2017).
> GO.db
GODb object:
| GOSOURCENAME: Gene Ontology
| GOSOURCEURL: ftp://ftp.geneontology.org/pub/go/godatabase/archive/latest-lite/
| GOSOURCEDATE: 2016-Sep21
| Db type: GODb
| package: AnnotationDbi
| DBSCHEMA: GO_DB
| GOEGSOURCEDATE: 2016-Sep26
| GOEGSOURCENAME: Entrez Gene
| GOEGSOURCEURL: ftp://ftp.ncbi.nlm.nih.gov/gene/DATA
| DBSCHEMAVERSION: 2.1
I've tried uninstalling and reinstalling the package, but the GOSOURCEDATE value remains unchanged.
I want to find out what sequence of R commands will allow me to load the newer annotations. Do I need to install a newer version of R?
The Bioconductor version information is as follows:
> BiocInstaller::biocLite()
BioC_mirror: https://bioconductor.org
Using Bioconductor 3.4 (BiocInstaller 1.24.0), R 3.3.2 (2016-10-31).
The output of the sessionInfo command is as follows (includes a lot of unrelated packages that my application also loads.
> 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=English_Canada.1252 LC_CTYPE=English_Canada.1252 LC_MONETARY=English_Canada.1252
[4] LC_NUMERIC=C LC_TIME=English_Canada.1252
attached base packages:
[1] parallel stats4 stats graphics grDevices utils datasets methods base
other attached packages:
[1] cowplot_0.8.0 ggplot2_2.2.1 xlsx_0.5.7 xlsxjars_0.6.1 rJava_0.9-8
[6] reshape2_1.4.2 metap_0.8 GO.db_3.4.0 annotate_1.52.1 XML_3.98-1.9
[11] org.Hs.eg.db_3.4.0 AnnotationDbi_1.36.2 IRanges_2.8.2 S4Vectors_0.12.2 Biobase_2.34.0
[16] BiocGenerics_0.20.0 homologene_1.0 magrittr_1.5 tidyr_0.7.1 dplyr_0.7.3
[21] readr_1.1.1 tmod_0.31
loaded via a namespace (and not attached):
[1] beeswarm_0.2.3 purrr_0.2.3 lattice_0.20-34 colorspace_1.3-2 htmltools_0.3.6 blob_1.1.0
[7] rlang_0.1.2 glue_1.1.1 DBI_0.7 bit64_0.9-7 RColorBrewer_1.1-2 bindrcpp_0.2
[13] bindr_0.1 plyr_1.8.4 pca3d_0.10 stringr_1.2.0 munsell_0.4.3 gtable_0.2.0
[19] htmlwidgets_0.9 memoise_1.1.0 knitr_1.17 httpuv_1.3.5 Rcpp_0.12.12 xtable_1.8-2
[25] scales_0.5.0 jsonlite_1.5 mime_0.5 bit_1.1-12 ellipse_0.3-8 hms_0.3
[31] digest_0.6.12 stringi_1.1.5 tagcloud_0.6 shiny_1.0.5 grid_3.3.2 tools_3.3.2
[37] bitops_1.0-6 rgl_0.98.1 lazyeval_0.2.0 RCurl_1.95-4.8 tibble_1.3.4 RSQLite_2.0
[43] pkgconfig_2.0.1 assertthat_0.2.0 R6_2.2.2 plotwidgets_0.4

I couldn't find your question on the support site, so I can give you one here.
It seems that you are using Bioconductor version 3.4. It appears that all of your annotation packages are out-of-date. If you want to use the current release annotations, you will have to update your version of R to the current release version (3.4.1) and then run the command BiocInstaller::biocLite("biocUpgrade").

Related

error "object ‘coef.cv.glmnet’ is not exported by 'namespace:glmnet' " while loading Lime package in R -

I've successfully installed Lime (and glmnet) in R but when I try loading it i receive an error:
> require(lime)
Loading required package: lime
Error: package or namespace load failed for ‘lime’:
object ‘coef.cv.glmnet’ is not exported by 'namespace:glmnet'
Searched online and can't seem to find a solution for this.
This is my sessioninfo()
> sessionInfo()
R version 3.6.1 (2019-07-05)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 17763)
Matrix products: default
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] stats graphics grDevices utils datasets methods base
other attached packages:
[1] glmnet_3.0 Matrix_1.2-17
loaded via a namespace (and not attached):
[1] Rcpp_1.0.3 rstudioapi_0.10 magrittr_1.5 tidyselect_0.2.5 munsell_0.5.0 colorspace_1.4-1 lattice_0.20-38 R6_2.4.0 rlang_0.4.1
[10] foreach_1.4.7 dplyr_0.8.3 tools_3.6.1 grid_3.6.1 gtable_0.3.0 iterators_1.0.12 lazyeval_0.2.2 assertthat_0.2.1 tibble_2.1.3
[19] crayon_1.3.4 purrr_0.3.3 ggplot2_3.2.1 codetools_0.2-16 shape_1.4.4 glue_1.3.1 compiler_3.6.1 pillar_1.4.2 scales_1.0.0
[28] pkgconfig_2.0.3
I've updated all my packages.
glmnet loads successfully
> library(glmnet)
Loaded glmnet 3.0
The recent major update of glmnet (which now does not export coef.cv.glmnet anymore) appears to have broken lime. You can see errors with the same cause in the CRAN tests. You can expect a fix by the package maintainer soon (or the package will be archived by CRAN). See also this bug report and the answer by the maintainer:
This is due to a recent breaking change in glmnet—lime will be updated soon to fix this

Rhandsontable displays on a locally deployed app, but not on app displayed in AWS EC2 Ubuntu 18.04 server

I'm trying to deploy on a private server an app that allows me to edit an RHandsontable object. For privacy reasons I cannot be showing a demonstration here.
I have successfully tested my app locally, but when I deploy it on my server the RHandsontable doesn't display, and the app "screen goes gray" after I start interacting there, so it doesn't allow any further interactions there.
This is how it looks on my Windows 10 browser. You can even see a 2 rhandsontables (that are empty because it has no selection whatsoever), that can be edited. The "Guardar" button is currently a dummy.
This is how it looks on AWS Ubuntu 18.04 Shiny Server. No rhandsontable loads (though the button loads). Same script, just different directories. I verified that the data loaded into both shiny apps were the same. You can also appreciate that the dummy button "Guardar" still appears.
I tried the same rendering equivalent data.tables from both the shiny and DT packages, leading to the same results as shown above.
Also, when I check my server logs at /var/log/shiny-server/ no issue arises (eg.: missing packages, broken code, etc). Last log goes as follows:
Attaching package: ‘dplyr’
The following objects are masked from ‘package:stats’:
filter, lag
The following objects are masked from ‘package:base’:
intersect, setdiff, setequal, union
Attaching package: ‘DT’
The following objects are masked from ‘package:shiny’:
dataTableOutput, renderDataTable
Listening on http://127.0.0.1:41757
This suggests me that I have a compatibility / interaction issue that arises in Shiny Server or in Ubuntu that doesn't arise in my PC.
I have seen different sources in Stack Overflow and in jrowen's GitHub page without any success, and I'd like to know if I'm missing anything.
There's a minor difference between R version between both machines (my Ubuntu VM is fresh, so some packages are updated). This could also cause a problem, but I'm not positive this could be the reason.
I also installed JRE on both instances (I also thought this could be caused due to a Java issue that I haven't fixed properly). Running java -version on my VM yields
openjdk version "10.0.2" 2018-07-17
OpenJDK Runtime Environment (build 10.0.2+13-Ubuntu-1ubuntu0.18.04.4)
OpenJDK 64-Bit Server VM (build 10.0.2+13-Ubuntu-1ubuntu0.18.04.4, mixed mode)
My personal computer is a Windows 10 Machine. Details:
R version 3.5.0 (2018-04-23)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)
Matrix products: default
locale:
[1] LC_COLLATE=Spanish_Spain.1252 LC_CTYPE=Spanish_Spain.1252
[3] LC_MONETARY=Spanish_Spain.1252 LC_NUMERIC=C
[5] LC_TIME=Spanish_Spain.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] readxl_1.1.0 lubridate_1.7.4 mailR_0.4.1 forcats_0.3.0
[5] stringr_1.3.1 purrr_0.2.5 readr_1.1.1 tidyr_0.8.1
[9] tibble_2.0.1 ggplot2_3.0.0.9000 tidyverse_1.2.1 DBI_1.0.0
[13] RODBC_1.3-15 DT_0.4 rhandsontable_0.3.7 Cairo_1.5-9
[17] openxlsx_4.1.0 knitr_1.20 dplyr_0.8.0.1 shiny_1.1.0
loaded via a namespace (and not attached):
[1] Rcpp_1.0.0 lattice_0.20-35 assertthat_0.2.0 digest_0.6.15 mime_0.5
[6] R6_2.2.2 cellranger_1.1.0 plyr_1.8.4 backports_1.1.2 evaluate_0.10.1
[11] httr_1.3.1 highr_0.7 pillar_1.3.1 rlang_0.3.1 lazyeval_0.2.1
[16] rstudioapi_0.7 R.oo_1.22.0 R.utils_2.8.0 rmarkdown_1.11 htmlwidgets_1.2
[21] munsell_0.5.0 broom_0.5.0 compiler_3.5.0 httpuv_1.4.4.1 modelr_0.1.2
[26] pkgconfig_2.0.2 htmltools_0.3.6 tidyselect_0.2.5 crayon_1.3.4 withr_2.1.2
[31] later_0.7.3 R.methodsS3_1.7.1 grid_3.5.0 nlme_3.1-137 jsonlite_1.5
[36] xtable_1.8-2 gtable_0.2.0 magrittr_1.5 scales_0.5.0 zip_1.0.0
[41] cli_1.0.1 stringi_1.1.7 promises_1.0.1 xml2_1.2.0 tools_3.5.0
[46] glue_1.3.0 hms_0.4.2 rsconnect_0.8.12 yaml_2.1.19 colorspace_1.3-2
[51] rvest_0.3.2 rJava_0.9-10 haven_1.1.2
The Ubuntu 18.04 machine goes as follows:
R version 3.5.3 (2019-03-11)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 18.04.2 LTS
Matrix products: default
BLAS: /usr/lib/x86_64-linux-gnu/blas/libblas.so.3.7.1
LAPACK: /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3.7.1
locale:
[1] LC_CTYPE=C.UTF-8 LC_NUMERIC=C LC_TIME=C.UTF-8
[4] LC_COLLATE=C.UTF-8 LC_MONETARY=C.UTF-8 LC_MESSAGES=C.UTF-8
[7] LC_PAPER=C.UTF-8 LC_NAME=C LC_ADDRESS=C
[10] LC_TELEPHONE=C LC_MEASUREMENT=C.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] readxl_1.3.1 DT_0.5 rhandsontable_0.3.7
[4] knitr_1.22 shiny_1.2.0 dplyr_0.8.0.1
loaded via a namespace (and not attached):
[1] Rcpp_1.0.1 magrittr_1.5 tidyselect_0.2.5 xtable_1.8-3
[5] R6_2.4.0 rlang_0.3.3 tools_3.5.3 xfun_0.5
[9] htmltools_0.3.6 assertthat_0.2.1 digest_0.6.18 tibble_2.1.1
[13] crayon_1.3.4 purrr_0.3.2 later_0.8.0 htmlwidgets_1.3
[17] promises_1.0.1 glue_1.3.1 mime_0.6 cellranger_1.1.0
[21] compiler_3.5.3 pillar_1.3.1 jsonlite_1.6 httpuv_1.5.0
[25] pkgconfig_2.0.2
In advance, thanks very much for your help. Please clarify at comments if you need any extra information (that I can provide).
Edit: I checked as well outputting data.tables instead of rhandsontables both locally and on Ubuntu and failed as well rendering only on my Ubuntu VM.
For anyone interested in my problem, it was actually related to a firewall issue, not to a server-side or compatibility issue.
When I accessed my application from a network that wasn't my organization's (i.e. my cell phone's shared internet or home network) I had no problem at all.

test.data.table errors R

Ran a test for data.table on my new installation of R and got the below errors:
> test.data.table()
Error in eval(exprs[i], envir) :
10 errors out of 8403 (lastID=1887, endian==little, sizeof(long
double)==16, sizeof(pointer)==8) in inst/tests/tests.Rraw on Tue Apr 03
11:28:16 2018. Search tests.Rraw for test numbers: 546, 1693.4, 1693.5,
1693.6, 1693.7, 1693.9, 1702.1, 1702.2, 1702.3, 1702.4.
All errors were of the kind:
Test testnum ran without errors but failed check that x equals y:
Where testnum is the test that failed (from above message).
Some more details:
R version 3.4.4 (2018-03-15)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1
Matrix products: default
locale:
[1] LC_COLLATE=English_Canada.1252 LC_CTYPE=English_Canada.1252 LC_MONETARY=English_Canada.1252
[4] LC_NUMERIC=C LC_TIME=English_Canada.1252
attached base packages:
[1] parallel stats graphics grDevices utils datasets methods base
other attached packages:
[1] rmarkdown_1.9 curl_3.1 caret_6.0-78 lattice_0.20-35 xts_0.10-1 zoo_1.8-1
[7] nlme_3.1-131.1 hexbin_1.27.2 testthat_2.0.0 plyr_1.8.4 knitr_1.20 bit64_0.9-7
[13] bit_1.1-12 ggplot2_2.2.1 lubridate_1.7.2 data.table_1.10.5 gmad_0.0.0.9000 reshape2_1.4.3
[19] reshape_0.8.7
loaded via a namespace (and not attached):
[1] httr_1.3.1 ddalpha_1.3.1.1 tidyr_0.8.0 sfsmisc_1.1-2 splines_3.4.4
[6] foreach_1.4.4 prodlim_1.6.1 assertthat_0.2.0 highr_0.6 stats4_3.4.4
[11] DRR_0.0.3 yaml_2.1.17 robustbase_0.92-8 ipred_0.9-6 pillar_1.2.1
[16] backports_1.1.2 glue_1.2.0 digest_0.6.15 colorspace_1.3-2 recipes_0.1.2
[21] htmltools_0.3.6 Matrix_1.2-12 psych_1.7.8 timeDate_3043.102 pkgconfig_2.0.1
[26] CVST_0.2-1 broom_0.4.3 purrr_0.2.4 scales_0.5.0 gower_0.1.2
[31] lava_1.6 tibble_1.4.2 withr_2.1.1 nnet_7.3-12 lazyeval_0.2.1
[36] mnormt_1.5-5 survival_2.41-3 magrittr_1.5 evaluate_0.10.1 MASS_7.3-49
[41] dimRed_0.1.0 foreign_0.8-69 class_7.3-14 tools_3.4.4 stringr_1.3.0
[46] kernlab_0.9-25 munsell_0.4.3 bindrcpp_0.2 compiler_3.4.4 RcppRoll_0.2.2
[51] rlang_0.2.0 grid_3.4.4 iterators_1.0.9 labeling_0.3 gtable_0.2.0
[56] ModelMetrics_1.1.0 codetools_0.2-15 R6_2.2.2 dplyr_0.7.4 bindr_0.1
[61] rprojroot_1.3-2 stringi_1.1.6 Rcpp_0.12.15 rpart_4.1-13 DEoptimR_1.0-8
[66] tidyselect_0.2.4
Using RStudio as the IDE, version 1.1.442 gmad is a local package (does not have any conflicting function names, basically a package to access some private APIs).
Not sure if this is cause for concern - didn't encounter this on any previous installations. I've seen the answer for test.data.table() error message but it's for an older version and I am seeing multiple errors (vs one).
EDIT
Restarted RStudio, test run fines when no packages (other than base) are loaded (not even data.table).
Get errors after loading some packages.
I've copied the output for both cases. Too long to post in this question - here's a pastebin link and here's another for GoogleDrive.
Regarding my local package gmad:
NAMESPACE imports:
import(data.table)
import(ggplot2)
import(httr)
importFrom(lubridate,round_date)
DESCRIPTION imports:
Imports:
data.table,
lubridate,
ggplot2,
ggmap,
httr
All other packages are installed from CRAN (versions noted in the session info above).
data.table and lubridate use the same function names for some date/time-related functions so the order of loading both libraries decides which function from which package is called by the unit tests.
See this issue for details: https://github.com/Rdatatable/data.table/issues/1135
I think to test the correct installation of data.table you shouldn't load lubridate at all.
If you want to use date/time functions in your code you have to choose which masking is better for you and load the libraries in the desired order...
library(lubridate)
library(data.table)
test.data.table() # runs without errors
If you reset the R session and load data.table first you will get some unit test errors
library(data.table)
library(lubridate)
test.data.table() # runs with unit test errors
saying e. g.
Running test id 546 Test 546 ran without errors but failed check that
x equals y:

Error in loading package SASxport: object ‘label<-.data.frame’ is not exported by 'namespace:Hmisc'

I'm trying to read data in the XPT format into R (the format can be found for example in the NHANES data). I found two functions doing this:
library("Hmisc")
sasxport.get("C:/path/file.XPT")
and
library("SASxport")
read.xport("C:/path/file.XPT")
The sasxport.get works, so I'm basically fine, but still inquisitive enough to understand (and solve) the following error: after the installation of the SASxport package, I cannot load it. When I run library("SASxport"), I get the error message:
Error: package or namespace load failed for ‘SASxport’:
object ‘label<-.data.frame’ is not exported by 'namespace:Hmisc'
Adopting this suggestion, I also ran
remove.packages(c("SASxport", "Hmisc"))
install.packages('Hmisc', dependencies = TRUE)
install.packages('SASxport', dependencies = TRUE)
what did not change the error message.
This is my sessionInfo():
R version 3.4.3 (2017-11-30)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)
Matrix products: default
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] stats graphics grDevices utils datasets methods base
other attached packages:
[1] Hmisc_4.1-1 ggplot2_2.2.1 Formula_1.2-2 survival_2.41-3 lattice_0.20-35
loaded via a namespace (and not attached):
[1] Rcpp_0.12.14 pillar_1.0.1 compiler_3.4.3 RColorBrewer_1.1-2 plyr_1.8.4
[6] base64enc_0.1-3 iterators_1.0.9 tools_3.4.3 rpart_4.1-11 digest_0.6.13
[11] tibble_1.4.1 gtable_0.2.0 htmlTable_1.11.1 checkmate_1.8.5 rlang_0.1.6
[16] icenReg_2.0.7 Matrix_1.2-12 foreach_1.4.4 rstudioapi_0.7 yaml_2.1.16
[21] gridExtra_2.3 coda_0.19-1 stringr_1.2.0 cluster_2.0.6 knitr_1.18
[26] htmlwidgets_0.9 grid_3.4.3 nnet_7.3-12 data.table_1.10.4-3 foreign_0.8-69
[31] latticeExtra_0.6-28 magrittr_1.5 scales_0.5.0 backports_1.1.2 codetools_0.2-15
[36] htmltools_0.3.6 splines_3.4.3 colorspace_1.3-2 stringi_1.1.6 acepack_1.4.1
[41] lazyeval_0.2.1 munsell_0.4.3
The last update of SASxport happend nearly two years ago (2016-03-11). So the Hmisc package it imports might have changed in the meantime. Looking up the Hmisc archive I found the version number on 2016-03-11 to be 3.17-2. So installing this version fixes the problem:
library("devtools")
install_version("Hmisc", version = "3.17-2")
Two reasons speak against using SASxport in this case:
You need to use a old version of a package which might happer your work in later steps.
SASxport needs Hmisc for a task that Hmisc can do already by itself, so SASxport is expendable when reading in XPT files.

Installed caret in R but unable to use in library

This is the code and error message I am getting:
> library(caret)
Error : object ‘semester’ is not exported by 'namespace:lubridate'
Error: package or namespace load failed for ‘caret’
I am using a mac. I also use this at work on a PC and haven't had any problems.
I also ran sessionInfo() as adivsed
> sessionInfo()
R version 3.3.3 (2017-03-06)
Platform: x86_64-apple-darwin13.4.0 (64-bit)
Running under: OS X Yosemite 10.10.5
locale:
[1] en_AU.UTF-8/en_AU.UTF-8/en_AU.UTF-8/C/en_AU.UTF-8/en_AU.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] lattice_0.20-34 factoextra_1.0.5 FactoMineR_1.36 e1071_1.6-8
[5] GGally_1.3.0 ggrepel_0.6.5 RColorBrewer_1.1-2 stringr_1.2.0
[9] tidyr_0.6.1 dplyr_0.7.3 data.table_1.10.4 ggplot2_2.2.1
loaded via a namespace (and not attached):
[1] reshape2_1.4.1 kernlab_0.9-25 splines_3.3.3
[4] colorspace_1.3-2 prodlim_1.6.1 survival_2.40-1
[7] rlang_0.1.2 ModelMetrics_1.1.0 glue_1.1.1
[10] bindrcpp_0.2 foreach_1.4.3 bindr_0.1
[13] plyr_1.8.4 lava_1.5 dimRed_0.1.0
[16] robustbase_0.92-7 timeDate_3012.100 munsell_0.4.3
[19] gtable_0.2.0 leaps_3.0 codetools_0.2-15
[22] class_7.3-14 DEoptimR_1.0-8 Rcpp_0.12.9
[25] scales_0.4.1 flashClust_1.01-2 ipred_0.9-6
[28] scatterplot3d_0.3-40 CVST_0.2-1 stringi_1.1.2
[31] RcppRoll_0.2.2 ddalpha_1.2.1 grid_3.3.3
[34] tools_3.3.3 magrittr_1.5 lazyeval_0.2.0
[37] tibble_1.3.4 cluster_2.0.5 DRR_0.0.2
[40] pkgconfig_2.0.1 MASS_7.3-45 Matrix_1.2-8
[43] lubridate_1.5.6 gower_0.1.2 assertthat_0.1
[46] reshape_0.8.6 iterators_1.0.8 R6_2.2.0
[49] rpart_4.1-10 nnet_7.3-12 nlme_3.1-131
You may have outdated dependencies. Try updating all installed packages. Then install "caret" with all dependencies : (install.packages("caret", dependencies = TRUE)). Worked for me!
I just ran into the same issue, except I got stuck at updating (reinstalling) the lubridate package. Some of the errors I got looked something like:
./cctz/include/civil_time_detail.h:37: error: expected nested-name-specifier before ‘year_t’
./cctz/include/civil_time_detail.h:37: error: ‘year_t’ has not been declared
./cctz/include/civil_time_detail.h:37: error: expected ‘;’ before ‘=’ token
./cctz/include/civil_time_detail.h:37: error: expected unqualified-id before ‘=’ token
turned out my gcc compiler (running RHEL 6.8) was too old (4.4.7). Since I couldn't upgrade the compiler itself, I installed a devtoolset.
then, I fixed my problem by enabling the devtoolset before running R:
scp enable devtoolset-4 R

Resources