Skip to content

Instantly share code, notes, and snippets.

View leipzig's full-sized avatar

Jeremy Leipzig leipzig

View GitHub Profile
import tiledb
import tiledbvcf
import numpy as np
cloud_uri = "tiledb://TileDB-Inc/vcf-1kg-dragen-v376"
# This is the config I need to pass
cloud_config = tiledb.Config()
cloud_cfg = tiledbvcf.ReadConfig(tiledb_config=cloud_config)
@leipzig
leipzig / sbg.yaml
Created July 1, 2021 15:22
all the public tool descriptions from https://igor.sbgenomics.com/public/apps
- ABRA2:
- https://igor.sbgenomics.com/raw/admin/sbg-public-data/abra2-12-germline/5
- https://igor.sbgenomics.com/raw/admin/sbg-public-data/abra2-12-somatic/2
- Admixture:
- https://igor.sbgenomics.com/raw/admin/sbg-public-data/admixture-1-3-0/4
- AmpliconQC:
- https://igor.sbgenomics.com/raw/admin/sbg-public-data/sbg-ampliconqc-amplicon-coverage/1
- https://igor.sbgenomics.com/raw/admin/sbg-public-data/sbg-ampliconqc-coverage-heatmap/1
- https://igor.sbgenomics.com/raw/admin/sbg-public-data/sbg-ampliconqc-mark-failed-amplicons/1
- https://igor.sbgenomics.com/raw/admin/sbg-public-data/sbg-ampliconqc-merge-coverage-beds/1
@leipzig
leipzig / drexelconnect.expect
Created November 22, 2020 15:12
expect script for connecting to drexel cisco anyconnect vpn
#!/usr/bin/expect
set PASSWD "<<yourpass>>"
set timeout 3
spawn /opt/cisco/anyconnect/bin/vpn connect vpn.drexel.edu
expect "Group:"
send -- "0\r"
expect "*Username:*"
send -- "<<yourusername>>\r"
expect "*Password:*"
send -- "$PASSWD\r"
@leipzig
leipzig / photoselection.R
Created April 4, 2019 14:52
selecting photos
mz<-c('007','011','017','020','025','046','076','077','090','102','104')
sa<-c('008', '017', '037', '058', '069', '109', '097', '102','028')
jl<-c('075','060','061','106','066','070','104','059','017','001','015','014','038','010','005','039','006','020','031','094')
rn<-str_pad(seq(1,109), 3, pad = "0")
pics<-data.frame(id=rn,mz=FALSE,sa=FALSE,jl=FALSE)
pics[pics$id %in% mz,"mz"]<-TRUE
pics[pics$id %in% sa,"sa"]<-TRUE
pics[pics$id %in% jl,"jl"]<-TRUE
{
"input_file": {
"class": "File",
"path": "https://raw.githubusercontent.com/briandoconnor/dockstore-tool-md5sum/master/md5sum.input"
},
"output_file": {
"class": "File",
"path": "s3://panoramabatch/md5sum.txt"
}
}
@leipzig
leipzig / gist:be08ae5442e32c9ce5b4362de9d61856
Created August 4, 2017 15:41
ImportError: libicuuc.so.54: cannot open shared object file: No such file or directory
python -c 'import rpy2.robjects as robjects'
this is almost certainly caused by conda-forge
to fix
conda install -c r r-base
@leipzig
leipzig / gist:a38fadecdf72ccde02fec1e67c404cf4
Created August 4, 2017 15:07
Installing packages in emacs using Melpa
#requires 24.4 or higher, just use conda version
M-x list-packages
C-v to scroll down
hit return on desired packages
C-x o to switch panes
go to [Install] hit return
---
title: "Template for writing scientific papers in R markdown"
author: "Petr Keil, pkeil@seznam.cz"
date: "11/1/2015"
output:
pdf_document:
fig_caption: yes
keep_tex: yes
number_sections: yes
html_document:

title: "Template for writing scientific papers in R markdown" author: "Petr Keil, pkeil@seznam.cz" date: "11/1/2015" output: pdf_document: fig_caption: yes keep_tex: yes number_sections: yes html_document:

@leipzig
leipzig / gb_client.pl
Last active August 29, 2015 14:05
access Haplogrep compatible input from a Genbank id
#!/usr/bin/perl
use LWP::UserAgent;
use HTTP::Request::Common;
my $userAgent = LWP::UserAgent->new(timeout => 1800); #a half-hour
my $request = POST 'http://mitomaster.mitomap.org/cgi-bin/websrvc.cgi', [
gb => $ARGV[0],
fileType => 'id',
output => 'hsd'