run_grammar: Generalized Renown Analysis of Molecular variance for Mixed...

View source: R/run_grammar.R

run_grammarR Documentation

Generalized Renown Analysis of Molecular variance for Mixed model Analysis R package

Description

run_grammar function calculates p-value and f-value.

Usage

run_grammar(K, Y, X, VC, max_itr, num.parallel, outPath, outName)

Arguments

K

is obtained from the Kinship function

Y

is the phenotype matrix, individual x phenotype

X

is the SNP matrix, individual x snp

VC

is obtained from the varComp function

max_itr

is specifies the number of permutations.

num.parallel

Number of parallel processes or a predefined socket cluster

outPath

is a parameter that specifies the path of the result file

outName

is a parameter that specifies the name of the result file

Value

p-value and f-value

Examples

   X <- as.matrix(data.table::fread(SNPData))
   Y <- as.matrix(data.table::fread(GeneExpressionData))
   
   K <- Kinship(X)
   VC <- varComp(K, Y, X)
   
   result <- run_grammar(K, Y, X, VC, max_itr = 4, num.parallel = 2, outPath = "./testdir/", outName = "result.txt")
   

2eding/GRAMMAR documentation built on Jan. 18, 2024, 6 a.m.