Skip to contents

Use laplace/double exponential distribution as prior. This is equivalent to Bayesian LASSO.

Usage

bayesLWeights(X, y, Z = NULL, ...)

Arguments

X

Numeric genotype / design matrix (samples x variants).

y

Numeric response (phenotype) vector of length nrow(X).

Z

Optional numeric matrix of fixed-effect covariates, or NULL.

...

Additional arguments forwarded to bayesAlphabetWeights / qgg.

Value

A numeric vector of effect-size weights, one per variant (column of X); columns dropped for zero variance receive weight 0.

Examples

data(eqtlRegionExample)
X <- eqtlRegionExample$X[, 1:30]
y <- eqtlRegionExample$yRes
bayesLWeights(X, y)
#> Type of analysis performed: st-blr-individual-level-dense-ld
#>  [1] -1.358898e-04 -2.038104e-04  1.674727e-04 -9.367960e-06 -5.249659e-05
#>  [6] -5.971718e-05 -1.514362e-04 -8.687408e-06 -5.268804e-05 -6.970188e-05
#> [11]  3.636643e-05 -1.365624e-04 -1.176079e-04 -4.310209e-05  1.110317e-05
#> [16]  1.323600e-04 -1.678129e-04 -1.364939e-04  3.576581e-05 -1.357210e-04
#> [21] -1.822342e-04 -1.576378e-05 -1.973659e-04  1.238695e-05 -4.761738e-05
#> [26] -1.530466e-04 -1.396502e-04 -7.954954e-06 -5.896762e-05 -4.539028e-05