standardizeBeta: Derive betas in the standardized model from betas in the...

Description Usage Arguments Value Examples

View source: R/varFrac.R

Description

Derive betas in the standardized model from betas in the general model

Usage

1
standardizeBeta(betaG, betaINT, maf, meanE, varE, type)

Arguments

betaG

is the vector of main genetic effects in the general model

betaINT

is the vector of interaction effects in the general model

maf

is the vector of the variants' frequency

meanE

is the mean of the exposure

varE

is the variance of the exposure

type

designates the coefficients to standardize: "G" for the main genetic effect and "I" for the interaction effects

Value

The vector of standardized effects

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
betaGs = rnorm(10, 0, 0.1)
betaIs = rnorm(10, 0, 0.05)
mafs = runif(10,0.05,0.95)
meanE = runif(1,-2,2)
varE = runif(1,0.5,1.5)
std_betaG = standardizeBeta(betaGs, betaIs, mafs, meanE, varE, "G")
std_betaI = standardizeBeta(betaGs, betaIs, mafs, meanE, varE, "I")

## Not run: 
std_betaI = standardizeBeta(betaGs, betaIs, mafs, meanE, varE, "anything different from G or I")

## End(Not run)

vincela/VarExp documentation built on May 29, 2019, 12:42 p.m.