compute_suff_stat {susieR}R Documentation

Compute sufficient statistics for input to susie_suff_stat

Description

Computes the sufficient statistics XX,Xy,yyX'X, X'y, y'y and nn after centering (and possibly standardizing) the columns of XX and centering yy to have mean zero. We also store the column means of XX and mean of yy.

Usage

compute_suff_stat(X, y, standardize = FALSE)

Arguments

X

An n by p matrix of covariates.

y

An n vector.

standardize

Logical flag indicating whether to standardize columns of X to unit variance prior to computing summary data

Value

A list of sufficient statistics (XtX, Xty, yty, n) and X_colmeans, y_mean.

Examples

data(N2finemapping)
ss = compute_suff_stat(N2finemapping$X, N2finemapping$Y[,1])


[Package susieR version 0.12.35 Index]