sim_no_family: Simulation without family history

Description Usage Arguments Details Value Warning

View source: R/sim_no_family.R

Description

Simulate genetic data, including genotypes, phenotype status and liabilities, for individuals.

Usage

1
sim_no_family(n, m, q, hsq, k, path)

Arguments

n

number of genotypes (individuals).

m

number of SNPS per genotype.

q

number of causal SNPs, i.e. SNPs that effect chances of having the phenotype.

hsq

squared heritability parameter.

k

prevalence of phenotype.

path

directory where the files will be stored. If nothing is specified, sim_no_family writes its files in the current working directory.

Details

As this function does not include family history, its resulting data cannot be used by assign_ltfh_phenotype() or assign_GWAX_phenotype().
For the methodology behind the simulation, see vignette("liability-distribution").
sim_no_family() makes use of parallel computation in order to decrease the running time. As at least one CPU core is left unused, the user should be able to do other work while the simulation is running.

Value

Does not return any value, but prints the following five files to the path parameter specified in the function call:

Warning

Simulating large datasets takes time and generates large files. For details on time complexity and required disk space, see vignette("sim-benchmarks").
The largest file generated is genotypes.ped. See convert_geno_file() to convert it to another file format, thereby reducing its size significantly.


FireGutter/geneference documentation built on Dec. 17, 2021, 8:27 p.m.