z_plot: Z plot

View source: R/plots.r

z_plotR Documentation

Z plot

Description

Creates a Z-score plot for SNPs, where Z = b / SE. This should follow a parabollic shape and so can be used to find certain SNPs which may not follow this shape. If 'plotly' is installed, the plot will be returned interactive.

Usage

z_plot(
  dat,
  snp_col = "SNP",
  beta_col = "beta.exposure",
  se_col = "se.exposure",
  pval_col = "pval.exposure",
  force_static = FALSE
)

Arguments

dat

A data.frame of data

snp_col

Column of SNP names (Optional)

beta_col

Column of MR beta estimates (Optional)

se_col

Column of standard errors for the beta estimates (Optional)

pval_col

Column of P values (Optional)

force_static

True for forcing the plot to be returned as a static plot (Optional)

Value

Plot


jwr-git/mrpipeline documentation built on Oct. 2, 2022, 3:41 p.m.