Skip to content

Instantly share code, notes, and snippets.

$ uptime
22:47:36 up 32 min, 1 user, load average: 0.00, 0.01, 0.05
$ls -l /etc/systemd/system/default.target
lrwxrwxrwx 1 root root 37 9月 2 22:25 /etc/systemd/system/default.target -> /lib/systemd/system/multi-user.target
@wakuteka
wakuteka / agqr.rb
Last active August 29, 2015 14:14 — forked from ybenjo/README.md
# -*- coding: utf-8 -*-
# record AGQR
# usage: use with crontab
# 29,59 * * * sleep 40; ruby agqr.rb
require 'yaml'
rtmpdump = '/usr/local/bin/rtmpdump'
ffmpeg = '/usr/bin/ffmpeg'
agqr_stream_url = 'rtmp://fms-base1.mitene.ad.jp/agqr/aandg22'
#!/usr/bin/perl
use strict;
use warnings;
my $target="ATcgAGCGTTTCG";
my $line;
open (DATAFILE, " < /home/work/biol/References/hg19/chr2.fa")) or die("error: no such file! \n!);
print $target."\n";
#!/usr/bin/perl
use strict;
use warnings;
my $target="ATcgAGCGTTTCG";
print $target."\n";
$target=uc("ATcgAGCGTTTCG");
weightedMedian <-function(v){
median(rep(v, times = v))
}
@wakuteka
wakuteka / cont_bp.awk
Created March 3, 2011 01:21
d]$ cat *.fa |awk '{if($1!~/^>/)sum+=length}END{print sum}' 173499994 count base pair
#!/bin/awk
BEGIN {
}
{
if($1!~/^>/)
{
sum += length
}
}
END {
#!/bin/sh
#$ -S /bin/bash
pwd
hostname
date
echo arg1=$1
sleep 20
date
@wakuteka
wakuteka / sample.Rnw
Created November 15, 2011 12:32
sweave
\documentclass[a4paper]{article}
\title{Sweave Example 1}
\author{Friedrich Leisch}
\begin{document}
\maketitle
In this example we embed parts of the examples from the
@wakuteka
wakuteka / index.snw
Created December 28, 2011 13:49
R2HTML sample
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd">
<!-- vim: set ft=html
Use the following R command to sweave this file:
Sweave("example2.snw",driver=RweaveHTML())
!-->
<<label=zebra,echo=FALSE,eval=TRUE>>=
source("brew-zebra.R")
@
<html>