Last active
April 22, 2016 14:52
-
-
Save nalimilan/905624dd5f44b4c020d57c16fcaab498 to your computer and use it in GitHub Desktop.
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
using DataFrames,DataFramesMeta, FreqTables | |
n=1000_000 | |
y=ASCIIString[string("id",i) for i in rand(1:10,n)]; | |
x=rand(1:10,n); | |
@time pda=PooledDataArray(y,UInt8); | |
@time f=freqtable(x); | |
@time f=freqtable(y); | |
@time f=freqtable(pda); | |
@time f=freqtable(x, pda); | |
d=DataFrame(x=P(x),y=P(y),pda=pda); | |
@time @by(d, :x, N=length(:x)); | |
@time @by(d, :y, N=length(:x)); | |
@time @by(d, :pda, N=length(:x)); | |
@time @by(d, (:x, :pda), N=length(:x)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment