Skip to contents

Extracts coefficients from an existing SuSiE fit or fits `susieR::susie()` from `X` and `y` before extracting weights.

Usage

susie_weights(X = NULL, y = NULL, susie_fit = NULL, retain_fit = FALSE, ...)

Arguments

X

Genotype matrix. Required when `susie_fit` is NULL.

y

Phenotype vector. Required when `susie_fit` is NULL.

susie_fit

Optional fitted SuSiE object.

retain_fit

If TRUE, stores the fitted object as an attribute on the returned weights.

...

Additional arguments passed to `susieR::susie()` when fitting.

Value

Numeric vector of variant weights.