Skip to content

Instantly share code, notes, and snippets.

Anurag Priyam yeban

View GitHub Profile
View features.xml
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!DOCTYPE DASFEATURES SYSTEM "http://www.biodas.org/dtd/dasgff.dtd">
<DASGFF>
<GFF version="1.0" href="http://localhost:4567/das/rubydas/features?segment=Si_gnF.scaffold02797:5943908,6066389;type=mRNA;type=exon;type=CDS;maxbins=3232">
<SEGMENT id="Si_gnF.scaffold02797" version="1.0" start="5939256" stop="6066389">
<FEATURE id="9216" label="maker-Si_gnF.scaffold02797-snap-gene-60.39-mRNA-1">
<TYPE id="mRNA"/>
<METHOD id="maker"/>
<START>6003626</START>
<END>6008125</END>
View ox_invalid_format_elements_overlap.rb
require 'ox'
Ox.parse(DATA.read)
__END__
<?xml version="1.0"?>
<!DOCTYPE BlastOutput PUBLIC "-//NCBI//NCBI BlastOutput/EN" "http://www.ncbi.nlm.nih.gov/dtd/NCBI_BlastOutput.dtd">
<BlastOutput>
<BlastOutput_program>tblastn</BlastOutput_program>
<BlastOutput_version>TBLASTN 2.2.30+</BlastOutput_version>
View jb_pl_test_output
# Failed test 'bin/draw-basepair-track.pl compiled ok'
# at tests/perl_tests/00.compile.t line 45.
# stdout:
# stderr: Can't locate GD/Image.pm in @INC (you may need to install the GD::Image module) (@INC contains: /Users/priyam/jbrowse/bin/../src/perl5/../../extlib/lib/perl5/5.18.2/darwin-thread-multi-2level /Users/priyam/jbrowse/bin/../src/perl5/../../extlib/lib/perl5/5.18.2 /Users/priyam/jbrowse/bin/../src/perl5/../../extlib/lib/perl5/darwin-thread-multi-2level /Users/priyam/jbrowse/bin/../src/perl5/../../extlib/lib/perl5 /Users/priyam/jbrowse/bin/../src/perl5/../../extlib/lib/perl5/darwin-thread-multi-2level /Users/priyam/jbrowse/bin/../src/perl5/../../extlib/lib/perl5 /Users/priyam/jbrowse/bin/../src/perl5 /Users/priyam/jbrowse/src/perl5/../../extlib/lib/perl5/darwin-thread-multi-2level /Users/priyam/jbrowse/src/perl5/../../extlib/lib/perl5 /Users/priyam/jbrowse/lib /Users/priyam/jbrowse/src/perl5 /Library/Perl/5.18/darwin-thread-multi-2level /Library/Perl/5.18 /Network/Library/Perl/5.18/darwin-thr
View ruby-setup.sh
#!/usr/bin/env sh
set -x
cd
# Download chruby to ~/.chruby.
wget -O /tmp/chruby-0.3.9.tar.gz https://github.com/postmodern/chruby/archive/v0.3.9.tar.gz
tar xvf /tmp/chruby-0.3.9.tar.gz -C /tmp
rm /tmp/chruby-0.3.9.tar.gz
View gff3_to_json.lua
function usage()
io.stderr:write(string.format("Usage: %s <GFF file>\n" , arg[0]))
os.exit(1)
end
if #arg < 1 then
usage()
os.exit(1)
end
View gt_segfault.gff
This file has been truncated, but you can view the full file.
##gff-version 3
scaffold00002 . contig 1 5659355 . . . ID=scaffold00002;Name=scaffold00002
scaffold00002 maker gene 5418413 5434733 . + . ID=maker-scaffold00002-augustus-gene-54.23;Name=maker-scaffold00002-augustus-gene-54.23
scaffold00002 maker mRNA 5418413 5434733 . + . ID=maker-scaffold00002-augustus-gene-54.23-mRNA-1;Parent=maker-scaffold00002-augustus-gene-54.23;Name=maker-scaffold00002-augustus-gene-54.23-mRNA-1;_AED=0.08;_eAED=0.08;_QI=0|0.2|0.33|0.83|0.4|0.33|6|2271|1028
scaffold00002 maker exon 5418413 5418704 . + . ID=maker-scaffold00002-augustus-gene-54.23-mRNA-1:exon:1799;Parent=maker-scaffold00002-augustus-gene-54.23-mRNA-1
scaffold00002 maker exon 5419004 5419181 . + . ID=maker-scaffold00002-augustus-gene-54.23-mRNA-1:exon:1800;Parent=maker-scaffold00002-augustus-gene-54.23-mRNA-1
scaffold00002 maker exon 5426189 5426463 . + . ID=maker-scaffold00002-augustus-gene-54.23-mRNA-1:exon:1801;Parent=maker-scaffold00002-augustus-gene-54.23-mRNA-1
View subpart.gff
scaffold00002 repeatmasker match 1244186 1244228 274 + . ID=scaffold00002:hit:1026:1.3.0.12;Name=species:R1_DPs|genus:LINE%2FR1;Target=species:R1_DPs|genus:LINE%2FR1 650 780 +
scaffold00002 repeatmasker match_part 1244186 1244228 274 + . ID=scaffold00002:hsp:1026:1.3.0.12;Parent=scaffold00002:hit:1026:1.3.0.12;Target=species:R1_DPs|genus:LINE%2FR1 650 780 +
scaffold00002 repeatmasker match 1261641 1261712 273 + . ID=scaffold00002:hit:1027:1.3.0.12;Name=species:GRANDE1_ZD-int|genus:LTR%2FGypsy;Target=species:GRANDE1_ZD-int|genus:LTR%2FGypsy 11010 11080 +
scaffold00002 repeatmasker match_part 1261641 1261712 273 + . ID=scaffold00002:hsp:1027:1.3.0.12;Parent=scaffold00002:hit:1027:1.3.0.12;Target=species:GRANDE1_ZD-int|genus:LTR%2FGypsy 11010 11080 +
# [...]
scaffold00002 repeatrunner protein_match 1241335 1241652 296 - . ID=scaffold00002:hit:1026:1.3.0.12;Name=gi|538540|pir||A40831;Target=gi|538540|pir||A40831 662 763 +
scaffold00002 repeatrunner match_part 1241335 1241652 296 - . ID=scaffold00002:hsp:1026:1.3.
@yeban
yeban / rooter.sh
Created Apr 26, 2012
cd to the project root (identified by the presence of a SCM directory, like .git, or .bzr)
View rooter.sh
# Copyright (C) 2011 Anurag Priyam - MIT License
#
# cd to the project root (identified by the presence of a SCM directory, like
# .git, or .bzr)
#
# Install
# -------
#
# Put something like this in your .zshrc:
#
@yeban
yeban / jekyll.tag-cloud.rb
Created Apr 3, 2012
Flexible, logarithmic distribution, tag cloud for Jekyll.
View jekyll.tag-cloud.rb
# Copyright (C) 2011 Anurag Priyam - MIT License
module Jekyll
# Jekyll plugin to generate tag clouds.
#
# The plugin defines a `tag_cloud` tag that is rendered by Liquid into a tag
# cloud:
#
# <div class='cloud'>
@yeban
yeban / nptel-dl.rb
Created Mar 6, 2012
Download video lectures from NPTEL.
View nptel-dl.rb
#!/usr/bin/env ruby
require 'rubygems'
require 'nokogiri'
require 'open-uri'
# FEM
page = "http://nptel.iitm.ac.in/video.php?subjectId=112106135"
download = "http://npteldownloads.iitm.ac.in/softlinks_mp4/112106135/lec%02d.mp4"
You can’t perform that action at this time.