mr_allmethods {MendelianRandomization}R Documentation

Mendelian randomization estimation using all methods

Description

The function mr_allmethods implements Mendelian randomization analyses using summarized data to calculate estimates (as well as standard errors and confidence interval limits) for all the methods included in the package (or alternatively for the group of methods chosen).

Usage

mr_allmethods(object, method = "all", ...)

## S4 method for signature 'MRInput'
mr_allmethods(object, method = "all", ...)

Arguments

object

An MRInput object.

method

Which estimation method should be included in the calculation. By default, all estimates are computed ("all"), but one can choose to show only the results of median-based, inverse-variance weighted, or MR-Egger methods separately through specifying "median", "ivw", "egger", or "main" (gives main results only, that is simple and weighted median, IVW, and MR-Egger).

...

Additional arguments to be passed to other methods.

Details

See mr_median, mr_egger, and mr_ivw for details of how each of the methods is implemented.

Value

An object of type MRAll with the following slots :

Data

The MRInput object used to calculate the various values.

Values

A data.frame containing the various estimates.

Method

The choice of methods estimated (default is "all").

References

See mr_median, mr_egger, and mr_ivw.

Examples

mr_allmethods(mr_input(bx = ldlc, bxse = ldlcse,
  by = chdlodds, byse = chdloddsse), method="main", iterations = 100)
  # iterations is set to 100 to reduce runtime for the mr_median method,
  # at least 10000 iterations are recommended in practice


[Package MendelianRandomization version 0.10.0 Index]