Skip to content

Instantly share code, notes, and snippets.

View ianyfchang's full-sized avatar

Ian YF Chang ianyfchang

  • Taipei, Taiwan
View GitHub Profile
# https://gist.github.com/bobthecat/5024079
bigcorPar <- function(x, nblocks = 10, verbose = TRUE, ncore="all",pvalue=0.05, ...){
library(ff, quietly = TRUE)
library(psych)
require(doMC)
if(ncore=="all"){
ncore = 30
registerDoMC(cores = ncore)
} else{
registerDoMC(cores = ncore)