Skip to content

Instantly share code, notes, and snippets.

View sjackman's full-sized avatar
🍁

Shaun Jackman sjackman

🍁
View GitHub Profile
@Geek-MD
Geek-MD / qemu_osx_rpi_raspbian_jessie.sh
Last active December 30, 2020 10:51 — forked from hfreire/qemu_osx_rpi_raspbian_jessie.sh
How to emulate a Raspberry Pi (Raspbian Jessie) on Mac OSX (Sierra)
# Install Homebrew
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
# Install QEMU OSX port with ARM support
brew install qemu
export QEMU=$(which qemu-system-arm)
# Dowload kernel and export location
brew install wget
wget https://github.com/dhruvvyas90/qemu-rpi-kernel/raw/master/kernel-qemu-4.4.34-jessie
@hfreire
hfreire / qemu_osx_rpi_raspbian_jessie.sh
Last active March 24, 2024 14:35
How to emulate a Raspberry Pi (Raspbian Jessie) on Mac OSX (El Capitan)
# Install QEMU OSX port with ARM support
sudo port install qemu +target_arm
export QEMU=$(which qemu-system-arm)
# Dowload kernel and export location
curl -OL \
https://github.com/dhruvvyas90/qemu-rpi-kernel/blob/master/kernel-qemu-4.1.7-jessie
export RPI_KERNEL=./kernel-qemu-4.1.7-jessie
# Download filesystem and export location
@stephenturner
stephenturner / install-gcc48-linuxbrew-centos6.md
Last active March 6, 2022 02:49
Installing gcc 4.8 and Linuxbrew on CentOS 6

Installing gcc 4.8 and Linuxbrew on CentOS 6

The GCC distributed with CentOS 6 is 4.4.7, which is pretty outdated. I'd like to use gcc 4.8+. Also, when trying to install Linuxbrew you run into a dependency loop where Homebrew's gcc depends on zlib, which depends on gcc. Here's how I solved the problem.

Note: Requires sudo privileges.

Resources:

@satta
satta / add_mrna.lua
Created June 1, 2015 20:48
add_mrna.lua
#!/usr/bin/env gt
function usage()
io.stderr:write(string.format("Usage: %s <GFF annotation>\n" , arg[0]))
os.exit(1)
end
if #arg < 1 then
usage()
end
@luugiathuy
luugiathuy / slide.html
Created April 6, 2015 10:18
Jekyll layout for reveal.js
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>
{% if page.title %}
{{ page.title }} | {{ site.title }}
{% else %}
{{ site.title }}
@hadley
hadley / ds-training.md
Created March 13, 2015 18:49
My advise on what you need to do to become a data scientist...

If you were to give recommendations to your "little brother/sister" on things that they need to do to become a data scientist, what would those things be?

I think the "Data Science Venn Diagram" (http://drewconway.com/zia/2013/3/26/the-data-science-venn-diagram) is a great place to start. You need three things to be a good data scientist:

  • Statistical knowledge
  • Programming/hacking skills
  • Domain expertise

Statistical knowledge

@jennybc
jennybc / 2014-10-12_stop-working-directory-insanity.md
Last active September 23, 2022 04:43
Stop the working directory insanity

There are packages for this now!

2017-08-03: Since I wrote this in 2014, the universe, specifically Kirill Müller (https://github.com/krlmlr), has provided better solutions to this problem. I now recommend that you use one of these two packages:

  • rprojroot: This is the main package with functions to help you express paths in a way that will "just work" when developing interactively in an RStudio Project and when you render your file.
  • here: A lightweight wrapper around rprojroot that anticipates the most likely scenario: you want to write paths relative to the top-level directory, defined as an RStudio project or Git repo. TRY THIS FIRST.

I love these packages so much I wrote an ode to here.

I use these packages now instead of what I describe below. I'll leave this gist up for historical interest. 😆

@rchikhi
rchikhi / alg1-ropebwt2.txt
Last active August 29, 2015 14:04
Illustration of Algorithm 1 in RopeBWT2 article
This document is a partial presentation of the RopeBWT2 pre-print
http://arxiv.org/abs/1406.0426
It is the transcript of a presentation made within the Medvedev group at Penn State
in July 2014. It focuses on illustrating some notions from the methods, and
illustrating and proving Algorithm 1. While this document does not cover the main
contribution of the RopeBWT2 paper, I hope it can be helpful towards understanding
the theoretical foundations that led to Algorithms 2 and 3.
@willurd
willurd / web-servers.md
Last active April 23, 2024 23:07
Big list of http static server one-liners

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000
@nickloman
nickloman / genbank_to_tbl.py
Created May 11, 2012 16:10
genbank_to_tbl.py
# requires biopython
# run like:
# genbank_to_tbl.py "my organism name" "my strain ID" "ncbi project id" < my_sequence.gbk
# writes seq.fsa, seq.tbl as output
import sys
from copy import copy
from Bio import SeqIO
def find_gene_entry(features, locus_tag):