GithubHelp home page GithubHelp logo

adams-charleen / mrgwasss Goto Github PK

View Code? Open in Web Editor NEW

This project forked from broccolito/mrgwasss

0.0 0.0 0.0 24 KB

MrGWASSS Cleans and Visualizes GWAS Summary Statistics

License: MIT License

Shell 0.58% R 98.84% Batchfile 0.58%

mrgwasss's Introduction

MrGWASSS

MrGWASSS cleans and visualizes GWAS summary statistics

Dependencies

Depends: 
    BioThingsClient.R (>= 0.99.1),
    devtools,
    dplyr,
    ggplot2,
    ggpubr,
    knitr,
    latex2exp,
    purrr,
    writexl
Remotes:  
    biothings/BioThingsClient.R

Usage

Load the package

# Load the package
if(!require("MrGWASSS")){
  devtools::install_github("Broccolito/MrGWASSS")
  library(MrGWASSS)
}

Load GWAS summary statistics into the workspace

Given the load_data function arguments:

load_data(
  file_name = "FHS_EA_MRS_5e8_snplist.txt",
  marker_name_column = "SNPID",
  chr_column = "CHR",
  pos_column = "POS",
  ref_column = "NEA",
  alt_column = "EA",
  pvalue_column = "p.value",
  delimiter = " "
)

To load the summary statistics from SAIGE, use:

data = load_data("HAPO_AA_Ogtt_diff_chr_MERGED.txt", 
                 by_marker = TRUE, 
                 marker_name_column = "SNPID", 
                 pvalue_column = "p.value", 
                 delimiter = " ")

To load the summary statistics from METAL, use:

data = load_data("METAANALYSIS1.TBL",
                 by_marker = TRUE,
                 marker_name_column = "MarkerName",
                 pvalue_column = "P.value",
                 delimiter = "\t")

Threshold the summary statistics

data_1e5 = threshold_data(data, 1e-5)

Annotate the stats

data_annotated = annotate_data(data_1e5)

Make Manhattan plots

plot_manhattan(data)

Make Q-Q plot

plot_qq(data)

mrgwasss's People

Contributors

broccolito avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.