Wrapper function around the original qpGraph program

qpgraph_wrapper(
  pref,
  graph,
  bin = "~np29/o2bin/qpGraph",
  parfile = NULL,
  outdir = ".",
  printonly = FALSE,
  badsnps = NULL,
  lambdascale = -1,
  inbreed = "NO",
  diag = 1e-04,
  blgsize = 0.05,
  outpop = "NULL",
  loadf3 = NULL,
  lsqmode = "NO",
  fstdmode = "NO",
  hires = "NO",
  forcezmode = "NO",
  zthresh = 0,
  allsnps = "NO",
  oldallsnps = "NO",
  doanalysis = "YES",
  bigiter = 100,
  initmix = 0,
  env = "",
  verbose = TRUE
)

Arguments

pref

Prefix of the packedancestrymap format genotype files.

graph

An admixture graph or qpGraph graph file

bin

Location of the qpGraph binary

parfile

qpGraph parameter file

outdir

Output directory

printonly

Should output be executed or the command just be printed?

badsnps

badsnps

lambdascale

lambdascale

inbreed

inbreed

diag

diag

blgsize

blgsize

outpop

outgroup population

loadf3

loadf3

lsqmode

least-squares mode. sets the offdiagonal elements of the block-jackknife covariance matrix to zero.

fstdmode

fstdmode

hires

hires

forcezmode

forcezmode

zthresh

zthresh

allsnps

allsnps

oldallsnps

oldallsnps

doanalysis

doanalysis

bigiter

bigiter

initmix

initmix

env

Export environmental variables. See examples.

verbose

Print progress updates

Value

A list with parsed qpGraph output

  1. edges: data frame

  2. score: scalar

  3. f2: data frame

Examples

if (FALSE) {
qpgraph_wrapper('genotype_prefix', example_graph,
                 bin = 'path/to/qpGraph')
}