This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
## get individual genotype from raw vcf | |
## output is tab-delimited chr \t start \t end \t ref \t alt \t GT \t ref,alt | |
usage=""" | |
read in tab-delimited bedfile: chr,start,end,ref,alt,gt | |
usage: python addallgt.py <infile> <outfile> | |
""" | |
import sys |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env python | |
import os | |
import sys | |
try: | |
SEQ_DIR = sys.argv[1] | |
except: | |
sys.stderr.write("Usage: python sanger2fastq.py <directory with.seq files>\n") | |
sys.exit(1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
## calculate N50 from fasta file | |
## N50 = contig length such that half of the contigs are longer and 1/2 of contigs are shorter | |
import commands | |
import sys | |
import os | |
from itertools import groupby | |
import numpy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import csv | |
import string | |
import datetime | |
import random | |
import json | |
import re | |
import sys | |
import os |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
BEDTOOLS=/usr/bin/bedtools/bin | |
ODIR=/data/dbase/ | |
GENOME=hg19 | |
SLOP=3000 | |
SLOP_OPTS='-l 3000 -r 3000' | |
GENE_BED=${IDIR}/${GENOME}_3kb.bed |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
title: "__RNAseq Summary__" | |
output: pdf_document | |
date: '`r Sys.Date()`' | |
documentclass: article | |
classoption: a4paper | |
geometry: margin=2cm | |
--- | |
```{r setup, include=FALSE} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/usr/bin/env/ python | |
usage=""" | |
# get dbSNP file | |
wget --timestamping 'ftp://hgdownload.cse.ucsc.edu/goldenPath/hg19/database/snp147Common.txt.gz' -O snp147Common.txt.gz | |
python dbsnp_clean.py <snp147Common.txt> <snp147common_clean.bed> | |
""" | |
if len(sys.argv) != 3: | |
print usage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
usage=""" | |
iupac_change.py <infile> <outfile> | |
change IUPAC nucleotide codes for tab delimited file with CHR, ID, REF, ALT columns | |
""" | |
import sys | |
import os |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
## calculate Ts/Tv across all sites (includes AC=0) | |
## file must be b/gzipped | |
## ./tstv.sh file.vcf.gz | |
VCF=$1 | |
# get count for transitions: | |
ag=$(zcat ${VCF} | awk '! /\#/' | awk '{if(length($4) == 1 && length($5) == 1) print}' | \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
usage=""" | |
## quality score distribution from fastq | |
gunzip -c fastq.gz | python qualDist.py | |
""" | |
import sys | |
num = 0 |
OlderNewer