Giter Club home page Giter Club logo

snipre-input's Introduction

#SnIPRE PREP SCRIPTS

The objective of the two scripts (snipre_prep_bash.sh and snipre_prep.R) is to create an input file for SnIPRE program (http://med.stanford.edu/bustamantelab/software.html).

##snipre_prep_bash.sh

This script takes in as input all the .bam files used to create the .vcf file, a fasta file and a gff file. The output is a .coverage file with the following format...

Group:Pos Total_Depth Average_Depth Depth_one Depth_two Depth_three Depth_four Depth_five

Group1.1:2 2 0.20 0 1 0 0 1

The bash script creates a .coverage file using GATK command, and then splits up the .coverage file based on unique Group name.

Note : This bash script must be run prior to snipre_prep.R as its output files are used by the R script.

The .jar file needed for this bash script (GenomeAnalysisTK.jar) can be downloaded from https://www.broadinstitute.org/gatk/.

##snipre_prep.R

This R script takes in eight command-line arguments to create an output file that can be used by the SnIPRE program. The eight command-line arguments are (in order)...

1) .vcf file
2) starting bee column number (positive integer) of the vcf file (1-based indexing)
3) ending bee column number (positive integer) of the vcf file (1-based indexing)
4) SnpEff file (for Format Specifications, see Part 2)	
5) gff file (for Format Specifications, see Part 5)
6) Folder where output files from snipre_prep_bash.sh are located (path name)
7) nout : outgroup x 2 (positive integer)
8) npop : population size x 2 (positive integer)

The output file created from this R script has the following format...

Group PR FR PS FS tsil trepl nout npop XP_12345678.1 10 3 3 10 445 483 20 16 XP_12345678.2 3 10 10 3 544 834 20 16

Usage of the R Script:

Rscript		snipre_prep.R		sample.vcf	10	17	syn_nonsyn_sample.eff	sample.gff	/coverage/Groups		16	20
Sani Patel, Winter 2015

snipre-input's People

Contributors

sunnypatel2141 avatar

Watchers

peterdfields avatar James Cloos 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.