Skip to contents

The mr_pcgmm function performs multivariable Mendelian randomization via the principal components generalized method of moments method.

Usage

mr_pcgmm(
  object,
  nx,
  ny,
  r = NULL,
  thres = 0.99,
  robust = TRUE,
  alpha = 0.05,
  ...
)

# S4 method for MRInput
mr_pcgmm(
  object,
  nx,
  ny,
  r = NULL,
  thres = 0.99,
  robust = TRUE,
  alpha = 0.05,
  ...
)

Arguments

object

An MRInput object.

nx

The sample size used to compute genetic associations with the exposure.

ny

The sample size used to compute genetic associations with the outcome.

r

The number of genetic principal components to be used to instrument the exposure. Default chooses r to explain 99.9% of variation in a sample weighted genetic correlation matrix (this can be varied by setting the thres parameter).

thres

The threshold value of variation in the sample weighted genetic correlation matrix explained by the genetic principal components. The default value is 0.99, indicating that 99% of variation is explained by the principal components. Note that if r and thres are both specified, then r will take precedence and thres will be ignored.

robust

Indicates whether overdispersion heterogeneity is accounted for in the model. Default is TRUE.

alpha

The significance level used to calculate the confidence interval. The default value is 0.05.

...

Additional arguments to be passed to the optimization routines to calculate the GMM estimate and overdispersion parameter.

Value

The output from the function is an PCGMM object containing:

Robust

TRUE if overdispersion heterogeneity was included in the model, FALSE otherwise.

Exposure

A character string with the name given to the exposure.

Outcome

A character string with the names given to the outcome.

Correlation

The matrix of genetic correlations.

Estimate

The causal estimate.

StdError

The standard error of the causal estimate.

CILower

The lower bound of the causal estimate based on the estimated standard error and the significance level provided.

CIUpper

The upper bound of the causal estimate based on the estimated standard error and the significance level provided.

Fstat

The first-stage F statistic for all genetic principal components used as instruments.

Overdispersion

The estimate of the overdispersion parameter.

PCs

The number of genetic principal components used to instrument the exposure.

Pvalue

The p-values associated with the estimates (calculated as Estimate/StdError as per Wald test) using a normal distribution.

Alpha

The significance level used when calculating the confidence intervals.

Heter.Stat

Heterogeneity statistic (Cochran's Q statistic) and associated p-value (for non-robust model only): the null hypothesis is that all genetic principal components estimate the same causal parameter; rejection of the null is an indication that one or more principal components may be pleiotropic.

Details

When a Mendelian randomization analysis is performed using correlated genetic variants from a single gene region, there is a tradeoff between using too few variants (and compromising on power) and using too many variants (in which case, estimates can be highly sensitive to small variation in the correlation matrix). This method performs dimension reduction on a weighted version of the genetic correlation matrix to form principal components based on the genetic variants, which are then used as instruments. It is recommended not to include very highly correlated variants in this method (say, r^2 > 0.95), but the method should cope well with variants correlated below this level.

This function runs a univariable version of the PC-GMM method, which can be used when there are a single exposure associated with variants at a given gene region.

This method provides two-sample univariable Mendelian randomization estimates and associated confidence intervals that account for overdispersion heterogeneity in dimension-reduced genetic associations (when robust = TRUE).

References

Description of the PC-GMM method: "Robust use of phenotypic heterogeneity at drug target genes for mechanistic insights: application of cis-multivariable Mendelian randomization to GLP1R gene region" (Preprint).

Examples

mr_pcgmm(mr_input(bx = calcium, bxse = calciumse,
   by = fastgluc, byse = fastglucse, correlation = calc.rho), nx=6351, ny=133010)
#> 
#> Univariable principal components generalized method of moments (PC-GMM) method
#> 
#> Number of principal components used : 4 
#> 
#> Robust model with overdispersion heterogeneity.
#> 
#> ------------------------------------------------------------------
#>  Method Estimate Std Error 95% CI       p-value F-stat
#>  PC-GMM    2.476     0.837 0.836, 4.116   0.003   12.7
#> ------------------------------------------------------------------
#> 
#> Overdispersion heterogeneity parameter estimate = -10.49837 
#> 
#> Heterogeneity test statistic = 1.6842