Comments (6)
Instead of using the ~
, can you use the full path? ~
is something that Bash provides and it's not necessarily recognized at the file system level. Looking at the rest of your error message, you need something like
julia> ENV["R_HOME"] = "/public/home/xuruiqiang/miniconda3/envs/RTIGER/lib/R"
from rcall.jl.
Dear Developer, @palday
Firstly, I apologize for the late reply, I’ve been tied up with too many trivial matters!
I tried the method you suggested, however, the same error still appears.
[xuruiqiang@login2 ~]$ source ~/miniconda3/bin/activate RTIGER
(RTIGER) [xuruiqiang@login2 ~]$ R RHOME
/public/home/xuruiqiang/miniconda3/envs/RTIGER/lib/R
(RTIGER) [xuruiqiang@login2 ~]$ which R
~/miniconda3/envs/RTIGER/bin/R
(RTIGER) [xuruiqiang@login2 ~]$ julia
_
_ _ _(_)_ | Documentation: https://docs.julialang.org
(_) | (_) (_) |
_ _ _| |_ __ _ | Type "?" for help, "]?" for Pkg help.
| | | | | | |/ _` | |
| | |_| | | | (_| | | Version 1.4.0 (2020-03-21)
_/ |\__'_|_|_|\__'_| | Official https://julialang.org/ release
|__/ |
julia> ENV["R_HOME"] = "/public/home/xuruiqiang/miniconda3/envs/RTIGER/lib/R"
"/public/home/xuruiqiang/miniconda3/envs/RTIGER/lib/R"
julia> ENV["JULIA_R_HOME"] = "/public/home/xuruiqiang/miniconda3/envs/RTIGER/bin/R"
"/public/home/xuruiqiang/miniconda3/envs/RTIGER/bin/R"
julia> using Pkg
julia> Pkg.build(PackageSpec(name="RCall", version="0.13.6"))
Building Conda → `~/.julia/packages/Conda/sDjAP/deps/build.log`
Building RCall → `~/.julia/packages/RCall/ffM0W/deps/build.log`
┌ Error: Error building `RCall`:
│ ERROR: LoadError: R cannot be found. Set the "R_HOME" environment variable to re-run Pkg.build("RCall").
│ Stacktrace:
│ [1] error(::String) at ./error.jl:33
│ [2] top-level scope at /public/home/xuruiqiang/.julia/packages/RCall/ffM0W/deps/build.jl:47
│ [3] include(::String) at ./client.jl:439
│ [4] top-level scope at none:5
│ in expression starting at /public/home/xuruiqiang/.julia/packages/RCall/ffM0W/deps/build.jl:10
└ @ Pkg.Operations /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.4/Pkg/src/Operations.jl:892
In addition, I also tried several other methods, all to no avail.
As you can see, R is in the conda environment, and Julia is in the system environment variables. I need to install RCall in Julia in order to use a specific R package.
I don’t know if you can provide any other suggestions to help identify where the problem lies and how to solve it.
Please forgive me as a programming novice and Julia newbie.
Any advice is needed !
from rcall.jl.
What happens if you do
ENV["R_HOME"] = "/public/home/xuruiqiang/miniconda3/envs/RTIGER/bin/R"
using Pkg
Pkg.build(PackageSpec(name="RCall", version="0.13.6"))
?
from rcall.jl.
emmm......it dose not work
julia> ENV["R_HOME"] = "/public/home/xuruiqiang/miniconda3/envs/RTIGER/bin/R"
"/public/home/xuruiqiang/miniconda3/envs/RTIGER/bin/R"
julia> using Pkg
julia> Pkg.build(PackageSpec(name="RCall", version="0.13.6"))
Building Conda → `~/.julia/packages/Conda/sDjAP/deps/build.log`
Building RCall → `~/.julia/packages/RCall/ffM0W/deps/build.log`
┌ Error: Error building `RCall`:
│ ERROR: LoadError: R_HOME is not a directory.
│ Stacktrace:
│ [1] error(::String) at ./error.jl:33
│ [2] top-level scope at /public/home/xuruiqiang/.julia/packages/RCall/ffM0W/deps/build.jl:42
│ [3] include(::String) at ./client.jl:439
│ [4] top-level scope at none:5
│ in expression starting at /public/home/xuruiqiang/.julia/packages/RCall/ffM0W/deps/build.jl:10
└ @ Pkg.Operations /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.4/Pkg/src/Operations.jl:892
Any chance it's a problem with the julia install?
from rcall.jl.
One more idea:
(RTIGER) [xuruiqiang@login2 ~]$ LD_LIBRARY_PATH="/public/home/xuruiqiang/miniconda3/envs/RTIGER/lib/R/lib/:$LD_LIBRARY_PATH" julia
julia> ENV["R_HOME"] = "/public/home/xuruiqiang/miniconda3/envs/RTIGER/lib/R"
julia> using Pkg
julia> Pkg.build(PackageSpec(name="RCall", version="0.13.6"))
from rcall.jl.
still erro.
(RTIGER) [xuruiqiang@login2 julia-1.4.0]$ LD_LIBRARY_PATH="/public/home/xuruiqiang/miniconda3/envs/RTIGER/lib/R/lib/:$LD_LIBRARY_PATH" julia
_
_ _ _(_)_ | Documentation: https://docs.julialang.org
(_) | (_) (_) |
_ _ _| |_ __ _ | Type "?" for help, "]?" for Pkg help.
| | | | | | |/ _` | |
| | |_| | | | (_| | | Version 1.4.0 (2020-03-21)
_/ |\__'_|_|_|\__'_| | Official https://julialang.org/ release
|__/ |
julia> ENV["R_HOME"] = "/public/home/xuruiqiang/miniconda3/envs/RTIGER/lib/R"
"/public/home/xuruiqiang/miniconda3/envs/RTIGER/lib/R"
julia> using Pkg
julia> Pkg.build(PackageSpec(name="RCall", version="0.13.6"))
Building Conda → `~/.julia/packages/Conda/sDjAP/deps/build.log`
Building RCall → `~/.julia/packages/RCall/ffM0W/deps/build.log`
┌ Error: Error building `RCall`:
│ ERROR: LoadError: R cannot be found. Set the "R_HOME" environment variable to re-run Pkg.build("RCall").
│ Stacktrace:
│ [1] error(::String) at ./error.jl:33
│ [2] top-level scope at /public/home/xuruiqiang/.julia/packages/RCall/ffM0W/deps/build.jl:47
│ [3] include(::String) at ./client.jl:439
│ [4] top-level scope at none:5
│ in expression starting at /public/home/xuruiqiang/.julia/packages/RCall/ffM0W/deps/build.jl:10
└ @ Pkg.Operations /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.4/Pkg/src/Operations.jl:892
from rcall.jl.
Related Issues (20)
- why building RCall.jl failed during the registration of an package HOT 2
- RCall.jl failed to build with Conda (23.3.1) HOT 3
- "is.na() applied to non-(list or vector) of type 'language'" when passing a Julia's boolean variable to R's smooth.spline HOT 2
- Unable to Pkg.build RCall HOT 4
- Find the number of arguments for an RFunction? HOT 1
- loading RCall in atreplinit fails because of RPrompt HOT 1
- Error: attempt to apply non-function HOT 5
- [BUG] ArgumentError: malformed expression in formula HOT 3
- If julia functions which was brought to R throws an error, no real error is thrown, but an error object is returned #216 HOT 3
- Feature Request: Add possibility to build RCall without having R_HOME set HOT 3
- ERROR: UndefVarError: `val` not defined
- Segmentation fault on closing julia HOT 7
- equal `==` is not working on `reval` HOT 2
- Feature Request: Make RCall depend dynamically on `R_HOME` HOT 9
- Feature Request: show/display methods for R plots like ggplot2 HOT 3
- Could we add a point in the docs about setting up CI ? HOT 6
- ERROR: REvalError: Loading required package: mvtnorm HOT 1
- Incorrect julia compat HOT 3
- Add support for TimeZones
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rcall.jl.