ddcorParallelExample.R

rm(list = ls(all.names = TRUE))
set.seed(12345)

library("DGCA",lib="~/.Rlib")

options(stringsAsFactors = FALSE)

message("loading data")
message(Sys.time())

data(darmanis) #loads daramanis
data(design_mat) #loads design_mat

######################

split = 5		#number of times to split the input. This means split**2 comparisons will be run (see below)
nPerms = 15		#permutations to run
outputfile = "output.test.txt" 		#output file (TSV)
input_data = darmanis 						#input dataframe
design_mat = design_mat 					#input design matrix
groups = c("oligodendrocyte", "neuron")		#groups to examine
num_cores = 2								#cores per worker
corrType="pearson"					#correlation type (pearson, spearman, bicor, mutualinformation)

######################

ddcorAllParallel(input_data, design_mat, groups, outputfile,
                 sigOutput=TRUE,corrType=corrType,adjust="perm",
                 nPerms=nPerms,verbose=TRUE,perBatch=split,
                 coresPerJob=num_cores,batchDir="minimal",testJob=TRUE,
                 memPerJob = 10000,timePerJob=60)
nosarcasm/DGCA documentation built on June 13, 2019, 11:49 p.m.