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
# updated 2018-01-31, hm | |
library(MonetDBLite) | |
library(reshape2) | |
library(shiny) | |
library(leaflet) | |
library(ggplot2) | |
library(ggthemes) | |
library(DBI) |
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
# Obsolete, See https://www.monetdb.org/blog/monetdblite-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
day_diff <- function(year, month, day, hour=0, min=0, sec=0, tz="UTC") { | |
as.numeric(difftime(ISOdatetime(year,month,day,hour,min,sec,tz), ISOdatetime(2000,1,1,12,0,0,"UTC"), units="days")) | |
} | |
# gah | |
d2r <- function(x) x * 0.0174532925 | |
r2d <- function(x) x * 57.2957795 | |
# Swabian power! | |
kepler <- function(M, e) { |
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
var https = require('https'); | |
var fs = require('fs'); | |
var net = require('net'); | |
var WebSocketServer = require('websocket').server; | |
// this works on ubuntu if you set chmod 755 on those files and the private dir | |
var httpsopts = { | |
key: fs.readFileSync('/etc/ssl/private/ssl-cert-snakeoil.key'), | |
cert: fs.readFileSync('/etc/ssl/certs/ssl-cert-snakeoil.pem') | |
}; |
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
# Test runner generator from a file with R functions | |
# Hannes Muehleisen, <hannes@muehleisen.org>, 2015-04-14 | |
test_runner <- function(fname) { | |
invisible(tryCatch ({ | |
conn <- textConnection("out", "w") | |
dput(do.call(fname, envir=test_ns, args=list()), file=conn) | |
close(conn) | |
out | |
}, error=function(e) { |
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
#include <assert.h> | |
#include <string.h> | |
#include <ctype.h> | |
#include <errno.h> | |
#include <stdio.h> | |
#include <signal.h> | |
#include <unistd.h> | |
#include <math.h> | |
#include <stdlib.h> |
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
# test runner generator from a file with R functions | |
# some grey magic, <hannes@cwi.nl>, 2015-04-14 | |
test_runner <- function(fname) { | |
invisible(tryCatch ({ | |
conn <- textConnection("out", "w") | |
dput(do.call(fname, envir=test_ns, args=list()), file=conn) | |
close(conn) | |
out | |
}, error=function(e) { |
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
RewriteEngine On | |
RewriteBase / | |
RewriteRule ^.*$ proxy.php |
NewerOlder