runCandidateMR: Run MRTryx Candidate MR analyses

View source: R/runCandidateMR.R

runCandidateMRR Documentation

Run MRTryx Candidate MR analyses

Description

This function takes the output from the candidateInstruments() function and formated data for the candidate-outcome associations and candidate-exposure associations. These formated datasets are produced from the TwoSampleMR::format_data() or the importPlink2() function.

Usage

runCandidateMR(
  dat,
  candidate_outcome_associations,
  candidate_exposure_associations,
  mr_method = "mr_ivw",
  include_outliers = FALSE,
  use_proxies = FALSE
)

Arguments

dat

output from the CandidateInstruments function

candidate_outcome_associations

formated data (formated using TwoSampleMR::format_data() or importPlink2()) for candidate SNP - outcome associations

candidate_exposure_associations

formated data (formated using TwoSampleMR::format_data() or importPlink2()) for candidate SNP - exposure associations

mr_method

default is IVW

include_outliers

When performing MR of candidate traits against exposures or outcomes, whether to include the original outlier SNP. Default is FALSE.

use_proxies

Whether to use proxies when looking up associations. FALSE by default for speed.

Value

List


asalzy/mrtryxhelpR documentation built on May 6, 2023, 11:52 p.m.