Skip to content

Instantly share code, notes, and snippets.

View ck37's full-sized avatar

Chris Kennedy ck37

View GitHub Profile
@andrie
andrie / foreach-parallel-progressbar.R
Created February 21, 2015 13:53
Creating progress bars from each parallel worker using foreach and doParallel
library(foreach)
library(iterators)
library(doParallel)
library(tcltk)
# Choose number of iterations
n <- 1000
cl <- makeCluster(8)
@domenic
domenic / 0-github-actions.md
Last active June 6, 2025 08:01
Auto-deploying built products to gh-pages with Travis

Auto-deploying built products to gh-pages with GitHub Actions

This is a set up for projects which want to check in only their source files, but have their gh-pages branch automatically updated with some compiled output every time they push.

A file below this one contains the steps for doing this with Travis CI. However, these days I recommend GitHub Actions, for the following reasons:

  • It is much easier and requires less steps, because you are already authenticated with GitHub, so you don't need to share secret keys across services like you do when coordinate Travis CI and GitHub.
  • It is free, with no quotas.
  • Anecdotally, builds are much faster with GitHub Actions than with Travis CI, especially in terms of time spent waiting for a builder.
@benmarwick
benmarwick / common-sci-symbols.md
Last active July 12, 2025 04:29
Commonly used scientific symbols in pandoc markdown

Commonly used scientific symbols in pandoc markdown

encoding is UTF-8, needs xelatex, like this:

---
output:
  pdf_document:
    latex_engine: xelatex
---
@cheuerde
cheuerde / R_OpenBLAS
Last active March 20, 2023 18:06
Compiling R against OpenBLAS #install #R
#####################################################
### How to compile R and link it against OpenBLAS ###
#####################################################
# Assuming no root priviledges on the destination machine,
# so we have to compile our software locally
# set default installation directory:
INSTDIR=$HOME/opt
@zachmayer
zachmayer / 2.15.sh
Last active December 19, 2015 14:09
cd /Library/Frameworks/R.framework/Resources/lib
# for vecLib use
ln -sf libRblas.vecLib.dylib libRblas.dylib
# for R reference BLAS use
ln -sf libRblas.0.dylib libRblas.dylib
@tdavis-ourfuture
tdavis-ourfuture / googlecheck.php
Last active July 9, 2018 15:05
Quick and dirty php command line script to check a list of domains for those that use gmail. For email nerds, fanboys and geniuses only.
#!/usr/bin/php
<?php
/**
* Checks a list of domains and outputs any that use Google.
*
* usage: php ./googlecheck.php filewithdomains
*
*/
stream_set_blocking(STDIN, 0);