snipar.pgs_am module
- snipar.pgs_am.delta_method(f, x, v_x)[source]
Delta method for estimating standard error of a function of a vector of parameters
- Args:
f (_type_): function of vector of parameters x (_type_): vector of parameters v_x (_type_): variance-covariance matrix of parameters
- Returns:
_type_: _description_
- snipar.pgs_am.estimate_k(delta, se_delta, h2f, se_h2f, rk, bound=True)[source]
Estimate k, the fraction of random-mating heritability explained by PGI
- Args:
delta (_type_): direct effect estimate se_delta (_type_): standard error of direct effect estimate h2f (_type_): family-based heritability estimate se_h2f (_type_): standard error of family-based heritability estimate rk (_type_): estimated correlation between parents for PGI
- Returns:
_type_: _description_
- snipar.pgs_am.estimate_r(delta, se_delta, h2f, se_h2f, rk, return_all=True, bound=True, allow_neg_r=False)[source]
- snipar.pgs_am.k_se(delta, se_delta, h2f, se_h2f, rk, se_rk)[source]
Standard error of estimate of k, the fraction of random-mating heritability explained by PGI
- Args:
delta (_type_): direct effect estimate se_delta (_type_): standard error of direct effect estimate h2f (_type_): family-based heritability estimate se_h2f (_type_): standard error of family-based heritability estimate rk (_type_): estimated correlation between parents for PGI
- Returns:
_type_: _description_
- snipar.pgs_am.se_alpha_from_alpha(delta, se_delta, alpha, se_alpha, r_delta_alpha, h2f, se_h2f, rk, se_rk)[source]
- snipar.pgs_am.se_alpha_from_beta(delta, se_delta, beta, se_beta, r_delta_beta, h2f, se_h2f, rk, se_rk)[source]
- snipar.pgs_am.se_v_eta_delta(delta, se_delta, ab, se_ab, r_delta_ab, h2f, se_h2f, rk, se_rk, is_beta=False)[source]