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
/** | |
* A little "class" to help out with tri state checkboxes. | |
*/ | |
function TriStateCheckbox(checkbox) { | |
var self = this; | |
var checkedVal = checkbox.prop("checked"); | |
var indeterminatePropName = "indeterminate"; | |
/** |
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
// creating a priority queue with a lambda less operator | |
auto pt_less = [&mat](const cv::Point& pt1, const cv::Point& pt2) -> bool { | |
return mat.at<uint8_t>(pt1) < mat.at<uint8_t>(pt2); | |
}; | |
priority_queue<cv::Point, vector<cv::Point>, decltype(pt_less)> erosion_candidates(pt_less); |
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
/** | |
* This callback will be called with the file that was dropped. | |
* @callback dropCallback | |
* @param file the file object | |
*/ | |
/** | |
* Create a file drop area | |
* @param activeElement | |
* the element that the user can drop on to trigger a callback | |
* @param highlightElement |
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
import csv | |
import requests | |
def build_ensembl_biomart_dict(dataset_name, key_attr, val_attr): | |
# see http://ensembl.org/biomart/martview/ for the web application | |
biomart_request_url_template = \ | |
'''http://ensembl.org/biomart/martservice?query=''' \ | |
'''<?xml version="1.0" encoding="UTF-8"?>''' \ | |
'''<!DOCTYPE Query>''' \ | |
'''<Query virtualSchemaName="default" formatter="CSV" header="0" uniqueRows="0" count="" datasetConfigVersion="0.6">''' \ |
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/Rscript | |
library("animation") | |
# reformat a directory full of R source files | |
tidy.all <- function(inDir = NULL, outDir = NULL, ...) { | |
if (is.null(inDir) || is.na(outDir)) | |
stop("inDir can't be null or NA") | |
if (!file.info(inDir)$isdir) | |
stop("inDir must be a directory") |
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 | |
echo "input directory: $1" | |
echo "output directory: $2" | |
for i in `ls $1` ; do echo "striping N and H calls from: $i" && egrep -v '(,N,)|(,N$)|(,H,)|(,H$)|(,n,)|(,n$)|(,h,)|(,h$)' $1/$i > $2/$i; done | |
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/perl | |
use strict; | |
use warnings; | |
my $status_output = `svn status @ARGV`; | |
my @split_status_lines = split(/\n/, $status_output); | |
foreach(@split_status_lines) | |
{ | |
if($_ =~ /^M.{5}\s+(.*)$/) |
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/ruby -w | |
################################################################################ | |
# Created By: Keith Sheppard (keith.sheppard@jax.org) | |
# Modification History: | |
# July 7, 2008: Initial revision created to run the liftover utility on | |
# the CGD (cgd.jax.org) imputed SNP data in comma-separated format | |
# | |
# This is a ruby script for running liftover to map SNPs in a source | |
# comma-separated file to a destination file using a different NCBI genome |
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
# attach and detach a package: | |
library("MouseDivGeno") | |
detach(package:MouseDivGeno) | |
# start in 64 bit mode: | |
R --arch x86_64 | |
# Stack-trace in R: | |
traceback() |
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
The liftover web app and command line download: | |
http://genome.ucsc.edu/cgi-bin/hgLiftOver | |
mapping from build # to dates and version numbers: | |
http://genome.ucsc.edu/FAQ/FAQreleases | |
chain files for converting from one build to another: | |
http://hgdownload.cse.ucsc.edu/downloads.html#mouse |
OlderNewer