Loading Magick package after tidyverse [duplicate] - r

This question already has answers here:
Rcpp package doesn't include Rcpp_precious_remove
(2 answers)
Closed 1 year ago.
I would like to loading the magick package in R, but not sure where the error is coming from. Using R version 4.0.5. I think the issue might with tidyverse package as I installed that after properly loading magick, but now it doesn't work at all. Using Windows and RStudio
library(magick)
Error: package or namespace load failed for ‘magick’:
.onLoad failed in loadNamespace() for 'magick', details:
call: set_magick_tempdir(tempdir())
error: function 'Rcpp_precious_remove' not provided by package 'Rcpp'

It may be better to not load tidyverse as a package. Perhaps, load those individual packages i.e. library(dplyr);library(tidyr) etc as this works without loading the library(tidyverse)
library(magick)
Linking to ImageMagick 6.9.12.3
Enabled features: cairo, fontconfig, freetype, heic, lcms, pango, raw, rsvg, webp
Disabled features: fftw, ghostscript, x11
The output of sessionInfo() is below
> sessionInfo()
R version 4.1.0 (2021-05-18)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Big Sur 11.5.1
Matrix products: default
BLAS: /Library/Frameworks/R.framework/Versions/4.1/Resources/lib/libRblas.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.1/Resources/lib/libRlapack.dylib
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] stats graphics grDevices utils datasets methods base
other attached packages:
[1] magick_2.7.2 lubridate_1.7.10 janitor_2.1.0 collapse_1.6.2 tibble_3.1.2 purrr_0.3.4 tidyr_1.1.3 dplyr_1.0.7 data.table_1.14.0
[10] overflow_0.2-4 stringr_1.4.0 reshape2_1.4.4
loaded via a namespace (and not attached):
[1] splines_4.1.0 gtools_3.8.2 Formula_1.2-4 latticeExtra_0.6-29 numDeriv_2016.8-1.1 pillar_1.6.1
[7] backports_1.2.1 lattice_0.20-44 glue_1.4.2 RcppEigen_0.3.3.9.1 digest_0.6.27 RColorBrewer_1.1-2
[13] checkmate_2.0.0 snakecase_0.11.0 minqa_1.2.4 colorspace_2.0-1 sandwich_3.0-1 htmltools_0.5.1.1
[19] Matrix_1.3-3 plyr_1.8.6 pkgconfig_2.0.3 broom_0.7.6 weights_1.0.4 scales_1.1.1
[25] gdata_2.18.0 jpeg_0.1-8.1 lme4_1.1-27 htmlTable_2.2.1 generics_0.1.0 ggplot2_3.3.3
[31] ellipsis_0.3.2 nnet_7.3-16 cli_2.5.0 survival_3.2-11 magrittr_2.0.1 crayon_1.4.1
[37] ps_1.6.0 mice_3.13.0 fansi_0.4.2 nlme_3.1-152 MASS_7.3-54 RcppArmadillo_0.10.4.0.0
[43] foreign_0.8-81 dreamerr_1.2.3 fixest_0.9.0 tools_4.1.0 lifecycle_1.0.0 munsell_0.5.0
[49] cluster_2.1.2 compiler_4.1.0 rlang_0.4.11 grid_4.1.0 nloptr_1.2.2.2 rstudioapi_0.13
[55] htmlwidgets_1.5.3 base64enc_0.1-3 boot_1.3-28 gtable_0.3.0 R6_2.5.0 gridExtra_2.3
[61] zoo_1.8-9 knitr_1.33 utf8_1.2.1 Hmisc_4.5-0 stringi_1.6.2 parallel_4.1.0
[67] Rcpp_1.0.6 vctrs_0.3.8 rpart_4.1-15 png_0.1-7 tidyselect_1.1.1 xfun_0.23

Related

Loading the package('kableExtra')

I'm a new user to rmarkdown and trying to learn how to format better tables for a report.
I had a report using the package "kableExtra" and it was fine. But now I cannot even load the package anymore and I do not know why.
This is the error I get:
"package of namespace load failed for 'kableExtra' in
library.dynam(lib, package, package.lib): DLL 'systemfonts' not
found: maybe not installed for this architecture? Execution halted"
Anyone can help me, please?
I am using RStudio 2022.02.0 Build 443
and R version 4.1.2 (2021-11-01) -- "Bird Hippie"
Thank you :)
sessionInfo() R version 4.1.2 (2021-11-01) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 10 x64 (build
19042)
Matrix products: default
locale: [1] LC_COLLATE=English_Canada.1252
LC_CTYPE=English_Canada.1252 LC_MONETARY=English_Canada.1252
LC_NUMERIC=C [5] LC_TIME=English_Canada.1252
attached base packages: [1] stats graphics grDevices utils
datasets methods base
other attached packages: [1] dplyr_1.0.8
loaded via a namespace (and not attached): [1] pillar_1.7.0
compiler_4.1.2 remotes_2.4.2 prettyunits_1.1.1 tools_4.1.2
testthat_3.1.2 digest_0.6.29 [8] pkgbuild_1.3.1
pkgload_1.2.4 evaluate_0.15 memoise_2.0.1 lifecycle_1.0.1
tibble_3.1.6 pkgconfig_2.0.3 [15] rlang_1.0.2 DBI_1.1.2
cli_3.2.0 rstudioapi_0.13 curl_4.3.2 yaml_2.3.5
xfun_0.30 [22] fastmap_1.1.0 withr_2.5.0 knitr_1.38
desc_1.4.1 generics_0.1.2 vctrs_0.3.8 fs_1.5.2
[29] devtools_2.4.3 rprojroot_2.0.2 tidyselect_1.1.2 glue_1.6.2
R6_2.5.1 processx_3.5.2 fansi_1.0.2 [36]
rmarkdown_2.13 sessioninfo_1.2.2 purrr_0.3.4 callr_3.7.0
magrittr_2.0.2 usethis_2.1.5 ps_1.6.0 [43]
ellipsis_0.3.2 htmltools_0.5.2 assertthat_0.2.1 utf8_1.2.2
cachem_1.0.6 crayon_1.5.1 brio_1.1.3

spacyr on MacOS: "Error: Python shared library not found, Python bindings not loaded"

I have read the similar questions and answers on Stack Overflow but have not cracked this issue. I could be doing something wrong based on those prior answers and just need further guidance. I've included the sessionInfo() below.
Problem
Using RStudio on a MacOS, I have the spacyr loaded. I also have miniconda installed on my computer. However, after running:
spacy_initialize()
I get:
Error: Python shared library not found, Python bindings not loaded.
Use reticulate::install_miniconda() if you'd like to install a Miniconda Python environment.
Which is puzzling since I have miniconda installed. I'm guessing that when I downloaded miniconda, I didn't do it as a "shared environment". Perhaps something is getting messed up because my 2017 Macbook came preloaded with an old version of Python, whereas the minconda one is Python 3.9.
I don't know. I'm prepared to do some uninstall/reinstalls and go into the terminal if necessary, but people might have to explain it to me like I'm five.
I appreciate the help.
sessionInfo()
R version 4.1.1 (2021-08-10) Platform: x86_64-apple-darwin17.0
(64-bit) Running under: macOS Big Sur 11.6
Matrix products: default LAPACK:
/Library/Frameworks/R.framework/Versions/4.1/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] reticulate_1.22 spacyr_1.2.1
textrecipes_0.4.1 recipes_0.1.17 [5] cleanNLP_3.0.3
hunspell_3.0.1 SnowballC_0.7.0 gt_0.3.1 [9]
magrittr_2.0.1 rmarkdown_2.11 htmltools_0.5.2 rlang_0.4.12
[13] stopwords_2.2 quanteda_3.1.0 text2vec_0.6
corpus_0.10.2 [17] bench_1.1.1 jiebaR_0.11 jiebaRD_0.1
janeaustenr_0.1.5 [21] hcandersenr_0.2.0 tidytext_0.3.2
forcats_0.5.1 stringr_1.4.0 [25] dplyr_1.0.7 purrr_0.3.4
readr_2.0.2 tidyr_1.1.4 [29] tibble_3.1.5
ggplot2_3.3.5 tidyverse_1.3.1 tokenizers_0.2.1
loaded via a namespace (and not attached): [1] colorspace_2.0-2
ellipsis_0.3.2 class_7.3-19 [4] rprojroot_2.0.2
fs_1.5.0 rstudioapi_0.13 [7] listenv_0.8.0
remotes_2.4.1 prodlim_2019.11.13 [10] fansi_0.5.0
lubridate_1.8.0 xml2_1.3.2 [13] codetools_0.2-18
splines_4.1.1 cachem_1.0.6 [16] rsparse_0.4.0
knitr_1.36 pkgload_1.2.3 [19] mlapi_0.1.0
jsonlite_1.7.2 RhpcBLASctl_0.21-247 [22] broom_0.7.9
dbplyr_2.1.1 png_0.1-7 [25] compiler_4.1.1
httr_1.4.2 backports_1.2.1 [28] assertthat_0.2.1
Matrix_1.3-4 fastmap_1.1.0 [31] cli_3.0.1
prettyunits_1.1.1 tools_4.1.1 [34] gtable_0.3.0
glue_1.4.2 float_0.2-6 [37] fastmatch_1.1-3
Rcpp_1.0.7 cellranger_1.1.0 [40] vctrs_0.3.8
timeDate_3043.102 xfun_0.27 [43] gower_0.2.2
globals_0.14.0 ps_1.6.0 [46] testthat_3.1.0
rvest_1.0.2 lifecycle_1.0.1 [49] devtools_2.4.2
future_1.22.1 MASS_7.3-54 [52] scales_1.1.1
ipred_0.9-12 lgr_0.4.3 [55] hms_1.1.1
parallel_4.1.1 yaml_2.2.1 [58] memoise_2.0.0
rpart_4.1-15 stringi_1.7.5 [61] desc_1.4.0
pkgbuild_1.2.0 lava_1.6.10 [64] pkgconfig_2.0.3
evaluate_0.14 lattice_0.20-45 [67] processx_3.5.2
tidyselect_1.1.1 parallelly_1.28.1 [70] R6_2.5.1
generics_0.1.0 DBI_1.1.1 [73] pillar_1.6.4
haven_2.4.3 withr_2.4.2 [76] nnet_7.3-16
survival_3.2-13 future.apply_1.8.1 [79] modelr_0.1.8
crayon_1.4.1 utf8_1.2.2 [82] tzdb_0.1.2
usethis_2.1.0 grid_4.1.1 [85] readxl_1.3.1
data.table_1.14.2 callr_3.7.0 [88] reprex_2.0.1
digest_0.6.28 RcppParallel_5.1.4 [91] munsell_0.5.0
sessioninfo_1.1.1
Someone provided me with a solution.
Have loaded: reticulate and spacyr packages.
Turns out that the reticulate package doesn't follow the standard way of indicating which version of Python you'd like to use, at least on a Mac OS, which has a system-level default that R wants to use.
The workaround is to set the system environment variable to tell reticulate to the attach the desired conda environment.
Sys.setenv( RETICULATE_PYTHON = with(conda_list(), python[ name == "spacy_condaenv" ]))
Next, run spacy_initialize(). Should work now.
Going forward, you'll need to put the Sys.setenv code (as written above) at the top of your script so that R sets the system environment to your liking right when you start a session.

How can I solve my problems with the installation of the text2vec package?

I'm trying to install the R package text2vec, I get the following error.
It says it cannot open a certain shared object file.
> install.packages("text2vec")
Error in dyn.load(file, DLLpath = DLLpath, ...) :
unable to load shared object '/var/R/library/rsparse/libs/rsparse.so':
float.so: cannot open shared object file: No such file or directory
Calls: <Anonymous> ... asNamespace -> loadNamespace -> library.dynam -> dyn.load
Execution halted
ERROR: lazy loading failed for package ‘text2vec’
* removing ‘/var/R/library/text2vec’
Warning in install.packages :
installation of package ‘text2vec’ had non-zero exit status
This is my session info:
R version 4.0.3 (2020-10-10)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Red Hat Enterprise Linux
Matrix products: default
BLAS/LAPACK: /usr/lib64/libopenblasp-r0.3.3.so
locale:
[1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8
[5] LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8 LC_PAPER=en_US.UTF-8 LC_NAME=C
[9] LC_ADDRESS=C LC_TELEPHONE=C LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] readr_1.4.0 usethis_2.0.1 purrr_0.3.4 rebus_0.1-3 testthat_3.0.3 stringi_1.6.2 scales_1.1.1
[8] tictoc_1.0.1 ggplot2_3.3.3 topicmodels_0.2-12 udpipe_0.8.6 tidytext_0.3.1 tidyr_1.1.3 stringr_1.4.0
[15] dplyr_1.0.5 odbc_1.3.2
loaded via a namespace (and not attached):
[1] Rcpp_1.0.6 lubridate_1.7.10 lattice_0.20-41 assertthat_0.2.1 utf8_1.2.1 slam_0.1-48
[7] plyr_1.8.6 cellranger_1.1.0 R6_2.5.0 stats4_4.0.3 quanteda_3.1.0 pillar_1.5.1
[13] cld3_1.4.1 rlang_0.4.10 readxl_1.3.1 rstudioapi_0.13 data.table_1.14.0 blob_1.2.1
[19] Matrix_1.2-18 rebus.base_0.0-3 config_0.3.1 bit_4.0.4 munsell_0.5.0 compiler_4.0.3
[25] janeaustenr_0.1.5 xfun_0.24 pkgconfig_2.0.3 tidyselect_1.1.0 tibble_3.1.0 rebus.numbers_0.0-1
[31] fansi_0.4.2 crayon_1.4.1 dbplyr_2.1.1 withr_2.4.1 SnowballC_0.7.0 grid_4.0.3
[37] gtable_0.3.0 lifecycle_1.0.0 DBI_1.1.1 magrittr_2.0.1 tokenizers_0.2.1 RcppParallel_5.1.4
[43] cli_2.4.0 reshape2_1.4.4 fs_1.5.0 NLP_0.2-1 xml2_1.3.2 stopwords_2.2
[49] ellipsis_0.3.1 generics_0.1.0 vctrs_0.3.7 fastmatch_1.1-3 wordcloud_2.6 RColorBrewer_1.1-2
[55] tools_4.0.3 bit64_4.0.5 glue_1.4.2 rebus.unicode_0.0-2 hms_1.0.0 rebus.datetimes_0.0-1
[61] parallel_4.0.3 yaml_2.2.1 tm_0.7-8 colorspace_2.0-0 knitr_1.33 modeltools_0.2-23
Can someone help me?
The problem here is the float package and the way R installs dependencies when not using "staged installs". What you can do here is to first reinstall the float package, and once it is reinstalled, reinstall the rsparse package. If that still doesn't work - and this is specific to float which uses dynamic linking - perhaps try installing float manually, changing the configuration to ensure that it uses your currently installed BLAS library (here openblas).

connection refused in R

I'm using multiMiR package to for miRNA target retrieval. Till yesterday this package was running fine and now it is showing following error:
library(multiMiR)
Error: package or namespace load failed for ‘multiMiR’:
.onLoad failed in loadNamespace() for 'multiMiR', details:
call: function (type, msg, asError = TRUE)
error: Failed to connect to multimir.org port 80: Connection refused
I tried to reinstall multiMiR package and restart rstudio. but still, it is showing the same error.
I don't understand how to solve this connection problem.
The below link I checked but I don't understand if that's the problem with my query here.
https://askubuntu.com/questions/676434/port-80-connection-refused
Any help will be appreciated.
please find below session info:
> sessionInfo()
R version 4.1.0 (2021-05-18)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 19042)
Matrix products: default
locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] Rcpp_1.0.7 lattice_0.20-44 corpcor_1.6.9 png_0.1-7
[5] Biostrings_2.60.1 snow_0.4-3 assertthat_0.2.1 digest_0.6.27
[9] foreach_1.5.1 utf8_1.2.1 RSpectra_0.16-0 R6_2.5.0
[13] GenomeInfoDb_1.28.1 stats4_4.1.0 RSQLite_2.2.7 httr_1.4.2
[17] ggplot2_3.3.5 pillar_1.6.1 zlibbioc_1.38.0 rlang_0.4.11
[21] rstudioapi_0.13 blob_1.2.1 S4Vectors_0.30.0 Matrix_1.3-4
[25] DT_0.18 reticulate_1.20 Rtsne_0.15 htmlwidgets_1.5.3
[29] RCurl_1.98-1.3 bit_4.0.4 munsell_0.5.0 umap_0.2.7.0
[33] compiler_4.1.0 pkgconfig_2.0.3 askpass_1.1 BiocGenerics_0.38.0
[37] htmltools_0.5.1.1 doSNOW_1.0.19 openssl_1.4.4 tidyselect_1.1.1
[41] KEGGREST_1.32.0 GenomeInfoDbData_1.2.6 tibble_3.1.2 matrixcalc_1.0-4
[45] IRanges_2.26.0 codetools_0.2-18 XML_3.99-0.6 fansi_0.5.0
[49] crayon_1.4.1 dplyr_1.0.7 bitops_1.0-7 grid_4.1.0
[53] jsonlite_1.7.2 gtable_0.3.0 lifecycle_1.0.0 DBI_1.1.1
[57] magrittr_2.0.1 scales_1.1.1 cachem_1.0.5 XVector_0.32.0
[61] doParallel_1.0.16 ellipsis_0.3.2 generics_0.1.0 vctrs_0.3.8
[65] iterators_1.0.13 tools_4.1.0 bit64_4.0.5 Biobase_2.52.0
[69] glue_1.4.2 purrr_0.3.4 M3C_1.14.0 parallel_4.1.0
[73] fastmap_1.1.0 AnnotationDbi_1.54.1 colorspace_2.0-2 BiocManager_1.30.16
[77] cluster_2.1.2 memoise_2.0.0
This seems to be a (hopefully) temporary issue. The error does not seem to be on your side - at the time of writing the site multimir.org is currently down, which is why you are getting an error.
As the package depends on connection to external database, I encourage you to raise an issue on their repository.
EDIT July 20th 2021: The site is now up.

Rstudio server crashes when loading large seurat object

I am working on the latest bioconductor_docker r-studio server (link) and I want to load a seurat object (size = 1.9GB) like
library(Seurat)
mca <- readRDS(<path_2_seurat_file>)
but I get the error:
19 Jul 2021 09:20:57 [rsession-rstudio] ERROR session hadabend; LOGGED FROM: rstudio::core::Error {anonymous}::rInit(const rstudio::r::session::RInitInfo&) src/cpp/session/SessionMain.cpp:675
I think this error might be due to some memory usage restriction as:
I can load this data on the r-studio on my computer (even when the docker container is running). The R session-info between the docker container and my computer (MacOS Cathalina.10.15.7) are similar.
I can load smaller seurat object on the rstudio-server (docker container).
So I tried running the docker container with the parameters -it --memory="8g" but it did not solve the problem.
Do you know any solutions to this problem or know how I could find a solution?
Here are supplementary information about the session:
Rstudio-server version: Version 1.4.1717
SessionInfo:
R version 4.1.0 (2021-05-18)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 20.04.2 LTS
Matrix products: default
BLAS/LAPACK: /usr/lib/x86_64-linux-gnu/openblas-pthread/libopenblasp-r0.3.8.so
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=C 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
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] SeuratObject_4.0.2 Seurat_4.0.3
loaded via a namespace (and not attached):
[1] nlme_3.1-152 matrixStats_0.59.0 spatstat.sparse_2.0-0 RcppAnnoy_0.0.18 RColorBrewer_1.1-2 httr_1.4.2
[7] sctransform_0.3.2 tools_4.1.0 utf8_1.2.1 R6_2.5.0 irlba_2.3.3 rpart_4.1-15
[13] KernSmooth_2.23-20 uwot_0.1.10 mgcv_1.8-36 DBI_1.1.1 lazyeval_0.2.2 colorspace_2.0-2
[19] tidyselect_1.1.1 gridExtra_2.3 compiler_4.1.0 cli_3.0.0 plotly_4.9.4.1 scales_1.1.1
[25] lmtest_0.9-38 spatstat.data_2.1-0 ggridges_0.5.3 pbapply_1.4-3 goftest_1.2-2 stringr_1.4.0
[31] digest_0.6.27 spatstat.utils_2.2-0 pkgconfig_2.0.3 htmltools_0.5.1.1 parallelly_1.26.1 fastmap_1.1.0
[37] htmlwidgets_1.5.3 rlang_0.4.11 rstudioapi_0.13 shiny_1.6.0 generics_0.1.0 zoo_1.8-9
[43] jsonlite_1.7.2 ica_1.0-2 dplyr_1.0.7 magrittr_2.0.1 patchwork_1.1.1 Matrix_1.3-4
[49] Rcpp_1.0.7 munsell_0.5.0 fansi_0.5.0 abind_1.4-5 reticulate_1.20 lifecycle_1.0.0
[55] stringi_1.6.2 MASS_7.3-54 Rtsne_0.15 plyr_1.8.6 grid_4.1.0 parallel_4.1.0
[61] listenv_0.8.0 promises_1.2.0.1 ggrepel_0.9.1 crayon_1.4.1 miniUI_0.1.1.1 deldir_0.2-10
[67] lattice_0.20-44 cowplot_1.1.1 splines_4.1.0 tensor_1.5 pillar_1.6.1 igraph_1.2.6
[73] spatstat.geom_2.2-0 future.apply_1.7.0 reshape2_1.4.4 codetools_0.2-18 leiden_0.3.8 glue_1.4.2
[79] data.table_1.14.0 png_0.1-7 vctrs_0.3.8 httpuv_1.6.1 gtable_0.3.0 RANN_2.6.1
[85] purrr_0.3.4 spatstat.core_2.2-0 polyclip_1.10-0 tidyr_1.1.3 scattermore_0.7 future_1.21.0
[91] assertthat_0.2.1 ggplot2_3.3.5 mime_0.11 xtable_1.8-4 later_1.2.0 survival_3.2-11
[97] viridisLite_0.4.0 tibble_3.1.2 cluster_2.1.2 globals_0.14.0 fitdistrplus_1.1-5 ellipsis_0.3.2
[103] ROCR_1.0-11
Update 1
When trying to read a cell_data_set object I now get the same error as before + another error.
library(monocle3)
cds <- readRDS(<path_to_cell_data_set_file>)
19 Jul 2021 12:50:10 [rsession-rstudio] ERROR session hadabend; LOGGED FROM: rstudio::core::Error {anonymous}::rInit(const rstudio::r::session::RInitInfo&) src/cpp/session/SessionMain.cpp:675
19 Jul 2021 12:50:10 [rsession-rstudio] ERROR system error 2 (No such file or directory) [path:/home/rstudio/.local/share/rstudio/sessions/active/session-975447f0/suspended-session-data/search_path/search_path_elements]; OCCURRED AT rstudio::core::Error rstudio::core::FilePath::openForRead(std::shared_ptrstd::basic_istream<char >&) const src/cpp/shared_core/FilePath.cpp:1427; LOGGED FROM: void rstudio::r::session::{anonymous}::reportDeferredDeserializationError(const rstudio::core::Error&) src/cpp/r/session/RInit.cpp:63
I also check (with file.exists()) and the file <path_to_cell_data_set_file> exits.
After some digging around I found this post on how to assign more memory to docker container.
I though that by adding -m 8g or -it --memory="8g" to the docker run command was enough to increase the memory limits. However, after typing docker stats, I found that my memory limit was stuck at 2GB.
I followed the instructions on this link which lead me to increase the memory limits in the > docker > Preferences > resources > Memory.
Now everything works like clockwork.

Resources