est_lambda is a function which allows users to obtain an unbiased estimate for lambda, a term used to describe the correlation between the SNP-outcome and SNP-exposure effect sizes, using a conditional log-likelihood approach. This correlation is affected by the number of overlapping samples between the two GWASs and the correlation between the exposure and the outcome. Thus, when using the function mr_simss, if the fraction of overlap and the correlation between exposure and outcome are unknown, it is recommended to employ est_lambda and use the value returned from est_lambda in mr_simss. Note: For greater accuracy in the estimation of lambda, it is advisable to use summary statistics of the entire set of unpruned SNPs from the exposure and outcome GWASs.

est_lambda(data, z.threshold = 0.5)

Arguments

data

A data frame to be inputted by the user containing summary statistics from the exposure and outcome GWASs. It must have at least five columns with column names SNP, beta.exposure, beta.outcome, se.exposure, and se.outcome. Each row must correspond to a unique SNP, identified by SNP.

z.threshold

A value which is used to obtain a subset of SNPs which have absolute z-statistics for both exposure and outcome GWASs less than this value. The method then assumes that both of the true SNP-outcome and SNP-exposure effect sizes of each SNP in this subset are approximately 0. The default setting is z.threshold=0.5.

Value

A value which is an estimate of lambda, the correlation between the SNP-outcome and SNP-exposure effect sizes, using a conditional log-likelihood approach. Note that this estimate is unbiased but potentially has a high degree of variance.

See also

https://amandaforde.github.io/mr.simss/articles/perform-MR-SimSS.html for illustration of the use of est_lambda with a toy data set and https://amandaforde.github.io/mr.simss/articles/derive-MR-SimSS.html for the theoretical derivation of this method based on a conditional log-likelihood approach for estimating lambda.