Skip to content

Instantly share code, notes, and snippets.

View al2na's full-sized avatar
💭
fishing 🎣

Altuna Akalin al2na

💭
fishing 🎣
View GitHub Profile
@hadley
hadley / .gitignore
Last active February 25, 2024 02:10
Benchmark different ways of reading a file
.Rproj.user
.Rhistory
.RData
*.Rproj
*.html
@ramnathv
ramnathv / gfm-table.md
Created March 16, 2012 16:08
GFM Table with knitr + ascii

Here is how you can make a table in GFM format using knitr + ascii

render_gfm()
gfm_table <- function(x, ...) {
    require(ascii)
    y <- capture.output(print(ascii(x, ...), type = "org"))
 # substitute + with | for table markup
anonymous
anonymous / group.operations.R
Created March 21, 2011 02:17
library(sqldf)
library(doBy)
library(plyr)
library(data.table)
n<-100000
grp1<-sample(1:750, n, replace=T)
grp2<-sample(1:750, n, replace=T)
d<-data.frame(x=rnorm(n), y=rnorm(n), grp1=grp1, grp2=grp2, n,
replace=T)