Skip to content

Instantly share code, notes, and snippets.

View ewels's full-sized avatar

Phil Ewels ewels

View GitHub Profile
@ewels
ewels / streamyard_hotkeys.js
Created March 1, 2024 09:22
StreamYard UserScript to add missing hotkeys
// ==UserScript==
// @name StreamYard overlay/music hotkeys
// @namespace https://phil.ewels.co.uk/
// @version 2024-02-29
// @description Add missing hotkeys for StreamYard
// @author Phil Ewels
// @match https://streamyard.com/*
// @icon https://www.google.com/s2/favicons?sz=64&domain=streamyard.com
// @grant none
// ==/UserScript==
@ewels
ewels / command.sh
Last active March 19, 2023 16:15
Analyse @nf-core AWS s3 storage
aws s3 ls s3://nf-core-awsmegatests --recursive > files.txt
@ewels
ewels / trace2json.py
Created September 14, 2017 15:17
Convert Nextflow Trace text file to JSON format
#!/usr/bin/env python
# Convert Nextflow text file to JSON format
import json
headers = []
data = {'trace': []}
with open ('NGI-RNAseq_trace.txt') as fh:
for l in fh:
s = l.split("\t")
@ewels
ewels / NF_logo.png
Created June 14, 2017 15:16
NextFlow Multipart HTML Emails
Save NextFlow logo as this file.
@ewels
ewels / bioconda_badges.html
Created August 24, 2016 19:59
Bioconda Poster Badges
<!DOCTYPE html>
<html lang="en">
<head>
<!--
BIOCONDA POSTER BADGE GENERATOR
Author: Phil Ewels <phil.ewels@scilifelab.se> (@ewels)
Date: August 2016
To add more templates, create in Adobe Illustrator.
@ewels
ewels / check_bismark_analysis.sh
Last active August 18, 2016 15:24
Quick and dirty script to check for common warning signs in a Bismark BS-seq methylation analysis
#!/bin/bash
# Check bisulfite analysis results for any modes of failure that I can think of.
# Assumes data is processed by Cluster Flow / bismark and is in subdirectories.
# For a basic quick summary, just run:
# bash check_bismark_analysis.sh
# To filter which subdirectories are checked, pass a glob expression. For example:
# bash check_bismark_analysis.sh run2_*
@ewels
ewels / rcolorbrewer_example.html
Created December 5, 2014 12:37
RColorBrewer example
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="generator" content="pandoc" />
@ewels
ewels / sra_illumina_stats.r
Created September 18, 2014 16:57
SRA Sequencing Platform Statistics
#' ---
#' title: "SRA Sequencing Platform Analysis"
#' author: "Phil Ewels"
#' date: September 2014
#' ---
#' The Sequence Read Archive [(SRA)](http://www.ncbi.nlm.nih.gov/sra)
#' contains the raw DNA-sequencing data for many published datasets.
#' We were interested in which sequencing platforms were prevalent,
#' or rather, how prevalent Illumina Sequencing is. We were specifically
@ewels
ewels / cytobands.pl
Created September 17, 2014 07:31
Cytoband Coordinate Converter
#!/usr/bin/perl
use CGI::Carp qw(fatalsToBrowser); # pipe errors to the browser instead of the terminal for debugging
use warnings;
use strict;
use Data::Dumper;
#print Dumper(\%args);
print "Content-type: text/plain\n\n";
#############################################################
# Name: Cytobands - Coordinates: Online Version #
@ewels
ewels / front-page.php
Created August 27, 2014 20:01
Child front-page.php for a full width carousel using the Unite wordpress theme: https://github.com/puikinsh/Unite-Theme
<?php
if ( get_option( 'show_on_front' ) == 'posts' ) {
get_template_part( 'index' );
} elseif ( 'page' == get_option( 'show_on_front' ) ) {
get_header();
while ( have_posts() ) : the_post();