Skip to content

Instantly share code, notes, and snippets.

View upendrak's full-sized avatar

Upendra Kumar Devisetty upendrak

View GitHub Profile
@davfre
davfre / bamfilter_oneliners.md
Last active August 4, 2024 03:10
SAM and BAM filtering oneliners
@ldong
ldong / md_to_rst.sh
Last active August 18, 2019 18:26 — forked from hugorodgerbrown/md_to_rst.sh
convert markdown to rst files
# This script was created to convert a directory full
# of markdown files into rst equivalents. It uses
# pandoc to do the conversion.
#
# 1. Install pandoc from http://johnmacfarlane.net/pandoc/
# 2. Copy this script into the directory containing the .md files
# 3. Ensure that the script has execute permissions
# 4. Run the script
#
# By default this will keep the original .md file
@stephenturner
stephenturner / deseq2-analysis-template.R
Created July 30, 2014 12:20
Template for analysis with DESeq2
## RNA-seq analysis with DESeq2
## Stephen Turner, @genetics_blog
# RNA-seq data from GSE52202
# http://www.ncbi.nlm.nih.gov/geo/query/acc.cgi?acc=gse52202. All patients with
# ALS, 4 with C9 expansion ("exp"), 4 controls without expansion ("ctl")
# Import & pre-process ----------------------------------------------------
# Import data from featureCounts

Dockerizing tools from source

Justin Payne, May 30 2015

Introduction

I get a lot of value out of putting bioinformatics tools in Docker containers, since once they're containerized with an automated build script (called a "Dockerfile") it's really easy to keep them up to date and manage their installations on different machines without their individual dependencies stepping all over each other. It's a really convenient way to try out new tools without taking the risk of borking your carefully-maintained "working" Linux install. Tools like boot2docker make Docker images runnable on non-Linux platforms, as well, resulting in improved portability of tools that might have platform (or even distro) specific dependencies. I've done this a couple of times, now, so I thought I'd share some tips and tricks.

@PoisonAlien
PoisonAlien / rna_seq_variant_pipeline.sh
Created August 7, 2015 09:35
RNA seq Variant calling pipeline according to gatk best practices
#!/bin/bash
#
# AUTHOR: Anand M.
# RNA-Seq variant calling pieline accoring to GATK Best practices.
# https://www.broadinstitute.org/gatk/guide/article?id=3891
#
# Call with following arguments
# bash rna_seq_variant_pipeline.sh <Input_Reads1.fq.gz> <Input_Reads2.fq.gz> <output_basename>
#
# Assumes STAR aligner is under path
@crawles
crawles / Spark Dataframe Cheat Sheet.py
Last active April 26, 2022 03:09 — forked from evenv/Spark Dataframe Cheat Sheet.py
Cheat sheet for Spark Dataframes (using Python)
# A simple cheat sheet of Spark Dataframe syntax
# Current for Spark 1.6.1
# import statements
from pyspark.sql import SQLContext
from pyspark.sql.types import *
from pyspark.sql.functions import *
#creating dataframes
df = sqlContext.createDataFrame([(1, 4), (2, 5), (3, 6)], ["A", "B"]) # from manual data
@leonawicz
leonawicz / bst.R
Last active September 7, 2020 02:14
Basic Bootrap Tour R wrapper example
# Bootstrap tour step
.bsTourStep <- function(i, id, title, content, pos = "right", tab = NULL){
id <- paste0("#", id)
x <- paste0(" {\n element: \"", id,
"\",\n title: \"", title,
"\",\n content: \"", content,
"\",\n placement: \"", pos, "\"")
if(i==1 && !is.null(tab)){
x <- paste0(x, ",\n onShow: function (tour) { $(\"", tab, "\").tab('show');}\n }")
} else {
@adefelicibus
adefelicibus / install-samtools-bcftools-and-htslib.md
Last active April 3, 2024 20:49
Install samtools, bcftools and htslib on linux

Install Samtools, BCFTools and htslib on linux

Install some build dependencies

sudo apt-get install autoconf automake make gcc perl zlib1g-dev libbz2-dev liblzma-dev libcurl4-gnutls-dev libssl-dev libncurses5-dev

[samtools]

@aparrish
aparrish / understanding-word-vectors.ipynb
Last active November 9, 2024 12:16
Understanding word vectors: A tutorial for "Reading and Writing Electronic Text," a class I teach at ITP. (Python 2.7) Code examples released under CC0 https://creativecommons.org/choose/zero/, other text released under CC BY 4.0 https://creativecommons.org/licenses/by/4.0/
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@darencard
darencard / maker_genome_annotation.md
Last active November 7, 2024 05:12
In-depth description of running MAKER for genome annotation.

Please see the most up-to-date version of this protocol on my blog at https://darencard.net/blog/.

Genome Annotation using MAKER

MAKER is a great tool for annotating a reference genome using empirical and ab initio gene predictions. GMOD, the umbrella organization that includes MAKER, has some nice tutorials online for running MAKER. However, these were quite simplified examples and it took a bit of effort to wrap my head completely around everything. Here I will describe a de novo genome annotation for Boa constrictor in detail, so that there is a record and that it is easy to use this as a guide to annotate any genome.

Software & Data

Software prerequisites:

  1. RepeatModeler and RepeatMasker with all dependencies (I used NCBI BLAST) and RepBase (ver