Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

create R package #131

Open
1 of 14 tasks
adokter opened this issue Oct 7, 2019 · 7 comments
Open
1 of 14 tasks

create R package #131

adokter opened this issue Oct 7, 2019 · 7 comments
Milestone

Comments

@adokter
Copy link
Owner

adokter commented Oct 7, 2019

adokter/bioRad#156 requires compilation of vol2bird within R, instead of accessing it through Docker.

To keep code bases separate, I suggest making an R-package for vol2bird that will be a dependency to bioRad (instead of integrating vol2bird C-code itself into bioRad)

R documentation for how to include external code:
https://cran.r-project.org/doc/manuals/r-release/R-exts.html#Non_002dR-scripts-in-packages

Hadley Wickham's tutorial on compiled code:
http://r-pkgs.had.co.nz/src.html

Examples of R packages based on C/C++ code:

Required steps:

@adokter
Copy link
Owner Author

adokter commented Oct 7, 2019

See this discussion of submodules. There is also a lot of criticism of submodules out there.

@adokter
Copy link
Owner Author

adokter commented Oct 8, 2019

For Windows compilation, need to find out if we can cross-compile using Rtools

@adokter adokter added this to the 1.0 milestone Nov 6, 2019
@bart1
Copy link
Contributor

bart1 commented Apr 15, 2020

Quick update I have been able to make a small toy package that converts files, it though still depends on the libvol2bird.so file, lets see if i can include the source

@bart1
Copy link
Contributor

bart1 commented Apr 15, 2020

I just got a version working where the library is compiled directly into the r package. It might still be a challenge to get it cran compatible but it works well. I will upload it later today

@bart1
Copy link
Contributor

bart1 commented Apr 15, 2020

Here is a quick mockup: https://github.com/bart1/Rvol2bird it is only tested on linux, and mostlikely does not directly compile on other OS's. Currently copies of the required libraries are included (no git subtrees). So it does not follow changes in the libaries

@adokter
Copy link
Owner Author

adokter commented Apr 16, 2020

Asked Simon Urbanek about proj4 header files in s-u/proj4#6

proj4 C library not available via proj4 package

@adokter
Copy link
Owner Author

adokter commented May 8, 2020

See adokter/bioRad#385 and https://docs.ropensci.org/rnoaa/ to read NOAA data into R directly. Unfortunately NEXRAD level2 and level3 data are currently not supported

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants