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/env python | |
import argparse | |
import os | |
import subprocess | |
import shlex | |
import sys | |
def _main(): | |
""" |
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
library(lattice) | |
gridensityplot <- function(...) { | |
densityplot(..., panel=function(...) { | |
panel.grid(h=-1, v=-1) | |
panel.densityplot(...) | |
}) | |
} |
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
library(lattice) | |
library(gregmisc) | |
myxyplot <- function(x, y, | |
xlab=deparse(substitute(x)), | |
ylab=deparse(substitute(y)), | |
xlim, | |
ylim, | |
nbins=c(50, 50), alpha=0.05, func=function(x){x}, sub="", heat.map=T) { | |
c <- cor.test(x, y) |
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/env python | |
import argparse | |
import sys | |
import itertools | |
def _main(): | |
parser = argparse.ArgumentParser(description='Transpose text array') | |
parser.add_argument('input', default=sys.stdin, nargs='?', type=argparse.FileType('r')) | |
parser.add_argument('output', default=sys.stdout, nargs='?', type=argparse.FileType('r')) |
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
library(lattice) | |
mybwplot <- function(x, y, interval=0.2, ylab=deparse(substitute(y)), xlab=deparse(substitute(x)), main="", sub="") { | |
bwplot(y ~ factor(trunc(x/interval)*interval), xlab=xlab, ylab=ylab, main=main, sub=sub, | |
panel=function(...){ | |
panel.grid(h=-1, v=0) | |
panel.bwplot(...) | |
}, scales=list(rot=c(45,0))) | |
} |
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
on showgrowl(theNotify, theImage, theTitle, theMessage) | |
tell application "Growl" | |
-- Make a list of all the notification types | |
-- that this script will ever send: | |
set the allNotificationsList to ¬ | |
{"Login", "Logout", "Present", "Text Message", "Invitation"} | |
-- Make a list of the notifications | |
-- that will be enabled by default. | |
-- Those not enabled by default can be enabled later |
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/env python | |
import argparse | |
import os | |
import os.path | |
import stat | |
def _main(): | |
parser = argparse.ArgumentParser(description='fix permission by suffix of filename and prefix of file') | |
parser.add_argument('dir', default='.', nargs='?', help='fix directory (default:%(default)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
library(lattice) | |
library(grid) | |
mydensityplot <- function(data, xlab=deparse(substitute(data)), grid=F, summary=F, ...) { | |
densityplot(data, xlab=xlab, ..., | |
panel=function(...){ | |
if (grid) { | |
panel.grid(h=-1, v=-1) | |
} | |
if (summary) { |
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/sh | |
# -*- sh -*- | |
: << =cut | |
=head1 NAME | |
cpuspeed - Plugin to monitor CPU speed | |
=head1 APPLICABLE SYSTEMS |
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
. $MUNIN_LIBDIR/plugins/plugin.sh | |
if [ "$1" = "autoconf" ]; then | |
if [ -r /sys/class/thermal/thermal_zone0/temp ];then | |
echo yes | |
exit 0 | |
else | |
echo "no (missing /sys/class/thermal/thermal_zone0/temp)" | |
exit 0 | |
fi |