This file contains hidden or 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
rule rawdata: | |
output: '{base}.raw.fa' | |
shell: 'echo "ACGTTGCA" > {output}' | |
rule atot: | |
input: '{base}.fa' | |
output: '{base}.atot.fa' | |
shell: 'cat {input} | sed "s/A/T/g" > {output}' | |
rule ctog: |
This file contains hidden or 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
import subprocess as sub | |
def create_pipes(cmd): | |
procs = {} | |
parts = cmd.split('|') | |
for i, part in enumerate(parts): | |
cmdparts = part.strip().split(' ') | |
if i == 0: | |
procs[i] = sub.Popen(cmdparts, stdout=sub.PIPE) |
This file contains hidden or 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
import luigi | |
from luigis_monkey_wrench import * | |
REF='human_17_v37.fasta' | |
INDIVIDUALS=['NA06984','NA07000'] | |
SAMPLES=['1','2'] | |
BASENAME='.ILLUMINA.low_coverage.17q_' | |
PICARDDIR='/sw/apps/bioinfo/picard/1.69/kalkyl/' | |
KNOWNSITES='/proj/g2014207/labs/gatk/ALL.chr17.phase1_integrated_calls.20101123.snps_indels_svs.genotypes.vcf' |
This file contains hidden or 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
# change to postgres user and open psql prompt | |
sudo -u postgres psql postgres | |
# list databases | |
postgres=# \l | |
# list roles | |
postgres=# \du | |
# create role |
This file contains hidden or 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
Manifest-Version: 1.0 | |
Class-Path: some-library.jar | |
Main-Class: MainClass |
This file contains hidden or 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
zi() { | |
if [[ ! -z $1 ]]; then | |
steps=$1; | |
SIZE=`grep 'FontName' ~/.config/Terminal/terminalrc | cut -d' ' -f 2` | |
NEWSIZE=$((SIZE + steps)) | |
REGEXPR='s/FontName.*/FontName=Monospace '$NEWSIZE'/g' | |
sed -i "$REGEXPR" ~/.config/Terminal/terminalrc | |
else | |
echo "Usage: zi [zoom steps]"; | |
fi; |
This file contains hidden or 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
defmodule ATGCCount do | |
def count(sequence), do: cnt(String.to_char_list(sequence),0,0) | |
def cnt([65|t],at,gc), do: cnt(t,at+1,gc) | |
def cnt([84|t],at,gc), do: cnt(t,at+1,gc) | |
def cnt([71|t],at,gc), do: cnt(t,at,gc+1) | |
def cnt([67|t],at,gc), do: cnt(t,at,gc+1) | |
def cnt([62|_],at,gc), do: {at,gc} | |
def cnt([],at,gc), do: {at,gc} | |
def cnt(_,0,0), do: {0,0} | |
def cnt([_|t], at, gc), do: cnt(t,at,gc) |
This file contains hidden or 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
inoremap jj <ESC> | |
noremap <silent> <c-z> :update<CR> | |
inoremap <silent> <c-z> <c-[>:update<CR> | |
vnoremap <silent> <c-z> :<c-c>:update<CR> | |
noremap <c-j> 4j | |
noremap <c-k> 4k | |
noremap <c-h> 4h | |
noremap <c-l> 4l |
This file contains hidden or 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
vs() { | |
vim $1; | |
source $1; | |
} | |
alias eb='vs ~/.bashrc' | |
alias ea='vs ~/.bash_aliases' | |
alias ev='vim ~/.vimrc' | |
alias ei='vs ~/.irodsEnv' | |
alias l='ls -1' | |
alias ltr='ls -1tr' |
This file contains hidden or 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
[xubuntu ~/install/irods]$ l | |
irods-database-plugin-postgres-1.3.deb | |
irods-icat-4.0.3-64bit.deb | |
[xubuntu ~/install/irods]$ sudo dpkg -i *.deb | |
[sudo] password for xubuntu: | |
Selecting previously unselected package irods-database-plugin-postgres. | |
(Reading database ... 179210 files and directories currently installed.) | |
Preparing to unpack irods-database-plugin-postgres-1.3.deb ... | |
Unpacking irods-database-plugin-postgres (1.3) ... | |
Selecting previously unselected package irods-icat. |