gemma_lmm: Run GEMMA and returns table of association statistics.

View source: R/gemma_lmm.R

gemma_lmmR Documentation

Run GEMMA and returns table of association statistics.

Description

A wrapper for running GEMMA genetic association test followed by reading of the results by read_gemma_assoc().

Usage

gemma_lmm(
  name,
  file_kinship,
  name_out = name,
  gemma_bin = "gemma",
  threads = 0,
  verbose = TRUE
)

Arguments

name

The shared name of the input plink BED/BIM/FAM files without extensions. Phenotype from FAM table is used.

file_kinship

The path to the kinship matrix file.

name_out

The base name of the output statistics file (default same as input name), which gets extension ".assoc.txt" added automatically.

gemma_bin

The path to the binary executable. Default assumes gemma is in the PATH.

threads

The number of threads to use. The values 0 (default), NA, or NULL use all threads available (the output of parallel::detectCores()).

verbose

If TRUE (default), prints the command line before it is executed.

Value

The table of genetic association statistics, as a tibble, read with read_gemma_assoc() (see that for more info).

See Also

gemma_kin() for estimating the kinship matrix with GEMMA.

read_gemma_assoc() for parsing the output of GEMMA.

delete_files_assoc() and delete_files_logtxt() for deleting the GEMMA output files.

system3(), used (with ret = FALSE) for executing GEMMA and error handling.

Examples

## Not run: 
data <- gemma_lmm( name, file_kinship, name_out )

## End(Not run)


OchoaLab/genbin documentation built on Nov. 14, 2024, 7:33 p.m.