Skip to content

Instantly share code, notes, and snippets.

View dragosmg's full-sized avatar
💭
I'm coding.

Dragoș Moldovan-Grünfeld dragosmg

💭
I'm coding.
View GitHub Profile
@stephhazlitt
stephhazlitt / macbook-pro-m1-2020-setup.md
Last active February 10, 2025 17:54
Macbook Pro (M1 2020) Set-up

MacBook Pro M1 (2020) Set-Up 👩‍💻

This is Steph's "living" document with instructions/documentation of my set-up on a MacBook Pro M1 (2020), with a focus on #rstats data science and meta tools 📊

Point & Click Software 🖱

App Install Plan

Critical

Q1. Are all the latest release versions of tidyverse and tidymodels packages already using cpp11?

All tidyverse packages that used Rcpp have been converted except for readxl and lubridate. We plan to finish converting the remainder of the packages in the next 6 months.

Q2. C++20 brings a lot of exciting features to the language, do you plan to also add a {cpp20} package too?

I agree! It is possible, but it would not be for at least 5 to 7 years from now, if ever. Compiler support and availablity often lags the language specifications significantly. However you can definitely use C++20 features with cpp11 in your package today if you like!

Q3. So writable:: is like not using const& in Rcpp?

if(interactive()) {
.__Rprofile_env__. <- new.env(parent = emptyenv())
.__Rprofile_env__.[["install"]] <- pak::pkg_install
attach(.__Rprofile_env__.)
library(usethis, warn.conflicts = FALSE)
library(conflicted)
conflict_prefer("filter", "dplyr")
conflict_prefer("sql", "dbplyr")
These code snippets have been tested on R 3.1.0 and Mac OS 10.9.3. They presumably do *not* work on R 2.X!
## Enter these commands in the Mac OS Terminal
# use faster vecLib library
cd /Library/Frameworks/R.framework/Resources/lib
ln -sf /System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/Versions/Current/libBLAS.dylib libRblas.dylib
# return to default settings
cd /Library/Frameworks/R.framework/Resources/lib