patzaw / BED

Biological Entity Dictionary (BED)
https://patzaw.github.io/BED/
GNU General Public License v3.0
8 stars 4 forks source link

Error in connectToBed function #1

Open MoritzTh opened 2 years ago

MoritzTh commented 2 years ago

Hi, I am having some trouble establishing a connection to BED. I followed the basic tutorial here. Installation of the package itself and dependencies worked out fine. However, when trying to connect to BED via

connectToBed(url="localhost:5454", remember=TRUE, useCache=TRUE)

it results in the following error:

Error in function (type, msg, asError = TRUE)  : 
  Failed to connect to localhost port 5454: Connection refused
BED is not connected.
You can connect to a BED database instance using the connectToBed function.
[1] FALSE
Warning message:
In rm("graph", envir = bedEnv) : object 'graph' not found

Any help on this would be highly appreciated, thanks in advance!


R session info:

R version 3.6.2 (2019-12-12)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Mojave 10.14.5

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRlapack.dylib

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] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] BED_1.4.7        visNetwork_2.1.0 neo2R_2.1.0     

loaded via a namespace (and not attached):
 [1] tidyselect_1.1.1  remotes_2.2.0     purrr_0.3.4       vctrs_0.3.8       generics_0.1.1   
 [6] testthat_2.3.2    miniUI_0.1.1.1    usethis_1.6.3     htmltools_0.5.2   base64enc_0.1-3  
[11] utf8_1.2.2        blob_1.2.1        rlang_0.4.12      pkgbuild_1.1.0    pillar_1.6.4     
[16] later_1.2.0       glue_1.6.0        withr_2.4.3       DBI_1.1.0         sessioninfo_1.1.1
[21] lifecycle_1.0.1   stringr_1.4.0     devtools_2.3.2    htmlwidgets_1.5.4 memoise_1.1.0    
[26] callr_3.5.1       fastmap_1.1.0     httpuv_1.6.5      ps_1.4.0          curl_4.3         
[31] fansi_1.0.2       Rcpp_1.0.8        xtable_1.8-4      backports_1.1.10  promises_1.2.0.1 
[36] DT_0.20           desc_1.2.0        pkgload_1.1.0     jsonlite_1.7.2    mime_0.12        
[41] fs_1.5.2          digest_0.6.29     stringi_1.7.6     processx_3.4.4    dplyr_1.0.7      
[46] shiny_1.7.1       rprojroot_1.3-2   bitops_1.0-7      cli_3.1.1         tools_3.6.2      
[51] magrittr_2.0.1    RCurl_1.98-1.5    tibble_3.1.6      crayon_1.4.2      pkgconfig_2.0.3  
[56] ellipsis_0.3.2    prettyunits_1.1.1 assertthat_0.2.1  rstudioapi_0.13   R6_2.5.1         
[61] compiler_3.6.2   
patzaw commented 2 years ago

Hi

I think you haven't setup a neo4j database. BED rely on a neo4j database to record the relationships between identifier.

Here are the 2 current options to instantiate such a database (the 2nd one is the fastest and the easiest if it suits your need).

Once the neo4j database runs you can connect to it as shown in the vignette.

You can also connect to a remote instance if it exists. For example, at my workplace, we have a running instance of the BED neo4j database to which we all connect (it's not accessible from outside because we also manage proprietary identifiers).

I hope it helps

Patrice