SearchingSampling.sumstats: Searhing-and-Sampling method

View source: R/MR.TSHT.R

SearchingSampling.sumstatsR Documentation

Searhing-and-Sampling method

Description

Get a possible confidence interval using searching method

Usage

SearchingSampling.sumstats(
  ITT_D,
  ITT_Y,
  SE_D,
  SE_Y,
  n1,
  n2,
  CI.init = NULL,
  a = 0.6,
  Sampling = TRUE,
  rho = NULL,
  M = 1000,
  prop = 0.1
)

Arguments

ITT_D

a numeric vector of GWAS summary statistics of the treatment

ITT_Y

a numeric vector of GWAS summary statistics of the outcome

SE_D

a numeric vector of standard errors of ITT_D

SE_Y

a numeric vector of standard errors of ITT_Y

n1

the sample size of GWAS summary statistics of the treatment

n2

the sample size of GWAS summary statistics of the outcome

CI.init

initial interval for beta. If NULL, it will be generated automatically. (default=NULL)

a

grid size for constructing beta grids (default=0.6)

Sampling

if TRUE, use the proposed sampling method; else use the proposed searching method. (default=TRUE)

rho

a numeric scalar denoting thresholding level used in the sampling property

M

sampling times. (default=1000)

prop

proportion of intervals kept when sampling. (default=0.1)

Value

CI

a numeric matrix denoting the confidence intervals for betaHat constructed by valid candidates for betaHat.

rule

a boolean scalar denoting whether the identification condition is satisfied or not.

VHat

valid instruments

CI.init

initial confidence interval for searching and sampling

TSHT.out

standard MR-TSHT output


MinhaoYaooo/MR.TSHT documentation built on May 22, 2022, 7:19 a.m.