Econometrics and Free Software by Bruno Rodrigues.
RSS feed for blog post updates.
Follow me on Mastodon, twitter, or check out my Github.
Check out my package that adds logging to R functions, {chronicler}.
Or read my free ebooks, to learn some R and build reproducible analytical pipelines..
You can also watch my youtube channel or find the slides to the talks I've given here.
Buy me a coffee, my kids don't let me sleep.

Reproducible data science with Nix, part 13 -- {rix} is on CRAN!

R Nix

Simplifies the creation of reproducible data science environments using the ‘Nix’ package manager, as described in Dolstra (2006) <ISBN 90-393-4130-3>. The included ‘rix()’ function generates a complete description of the environment as a ‘default.nix’ file, which can then be built using ‘Nix’. This results in project specific software environments with pinned versions of R, packages, linked system dependencies, and other tools. Additional helpers make it easy to run R code in ‘Nix’ software environments for testing and production.

After 15 months of coding, 1364 commits, 143 closed issues, 175 closed PRs, an rOpenSci pre-review, an rOpenSci review, {rix} is finally on CRAN!

You can now install {rix} using good old install.packages(). Soon, {rix} will also be included into the nixpkgs collection of packages, meaning that you will be able to install {rix} with Nix.

Important sidenote: as it so happened, there is currently a bug in the released CRAN version that we thought we had solved, which we did, but only partially. When running rix::rix() two files should be generated: a default.nix and an .Rprofile for your project. It turns out that this file can be empty. If it is, run rix::rix_init(rprofile_action = "overwrite") to generate a proper .Rprofile. This is important, especially on Mac or if you have a system-wide library of packages! We will submit a fix asap.

If you want to watch a 5-Minute video introduction:

Btw, here is what scc has to say about the estimated cost of the project:

scc --format=html-table --avg-wage 100000 .

Language Files Lines Blank Comment Code Complexity Bytes
YAML 61 2798 320 174 2304 0 69187
R 33 4515 483 1225 2807 389 153288
Nix 10 781 95 0 686 32 18644
Markdown 5 1371 339 0 1032 0 63758
JSON 1 147 0 0 147 0 4637
Plain Text 1 41 0 0 41 0 2269
Total 111 9653 1237 1399 7017 421 311783

Estimated Cost to Develop (organic) $371,264 - Estimated Schedule Effort (organic) 7.59 months - Estimated People Required (organic) 2.45

Don’t hesitate to give {rix} a try and let us know how it goes!

Hope you enjoyed! If you found this blog post useful, you might want to follow me on Mastodon or twitter for blog post updates and buy me an espresso or paypal.me, or buy my ebooks. You can also watch my videos on youtube. So much content for you to consoom!

Buy me an EspressoBuy me an Espresso